How does OptimizedAllocate work when called in un-optimized code?

21 views
Skip to first unread message

Tony Godspeed

unread,
Feb 23, 2021, 2:39:18 PM2/23/21
to v8-dev
OptimizedAllocate can be called in CodeStubAssembler::Allocate https://source.chromium.org/chromium/chromium/src/+/master:v8/src/codegen/code-stub-assembler.cc;l=1254;drc=6b915141921db226707d6b4aa21144890b682cfe;bpv=1;bpt=1

How does this work when an unoptimized code paths call this function? It looks like OptimizedAllocate adds a node to the graph which shouldn't do anything when called from un-optimized code.

Jakob Gruber

unread,
Feb 24, 2021, 12:52:20 AM2/24/21
to v8-...@googlegroups.com
On Tue, Feb 23, 2021 at 8:39 PM Tony Godspeed <tonygod...@gmail.com> wrote:
OptimizedAllocate can be called in CodeStubAssembler::Allocate https://source.chromium.org/chromium/chromium/src/+/master:v8/src/codegen/code-stub-assembler.cc;l=1254;drc=6b915141921db226707d6b4aa21144890b682cfe;bpv=1;bpt=1

How does this work when an unoptimized code paths call this function? It looks like OptimizedAllocate adds a node to the graph which shouldn't do anything when called from un-optimized code.

By 'unoptimized code', do you mean CSA/tq? The MemoryOptimizationPhase runs on the CSA pipeline as well, that's where AllocateRaw nodes are lowered for builtins.
 

--
--
v8-dev mailing list
v8-...@googlegroups.com
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to v8-dev+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/v8-dev/7e5d174e-d9e8-47a9-b319-b6e2ce59bd76n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages