• Jakob Gruber's avatar
    [osr] Two fixes in the OSR code cache · 4e046cea
    Jakob Gruber authored
    1: Clear cache entry 0 before overwriting it to maintain bookkeeping of
    the SharedFunctionInfo's OSR code cache state, which tracks how many
    cache entries there are for this particular SFI.
    
    2: When inserting into the code cache, we don't know in advance whether
    the entry is already present or not (this could happen with multiple
    simultaneous compile jobs from different closures of the same SFI).
    
    Fixed: chromium:1314644
    Bug: v8:12161
    Change-Id: I0085a3a6e0c1879c3d483853220e654aa03660ac
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3578643Reviewed-by: 's avatarLeszek Swirski <leszeks@chromium.org>
    Commit-Queue: Jakob Linke <jgruber@chromium.org>
    Cr-Commit-Position: refs/heads/main@{#79912}
    4e046cea
osr-optimized-code-cache.cc 11.2 KB