Search
Active

0
Sign in to vote
0
Sign in to vote
Sign in
to vote
Type: Bug
ID: 462067
Opened: 5/30/2009 6:20:54 AM
Access Restriction: Public
0
Workaround(s)
0
User(s) can reproduce this bug
'Phx.Common.Opcodes.Alloca' not implemented for X86 architecture. Using it leads to assertion failures.

But is there any normal way to allocate arbitrary byte array on stack?
In C# can do this via 'stackalloc type[size]'
In Visual C++ it can be done using '_alloca' function.
Details (expand)
Product Language
English
Version
Phoenix RDK
Category
Phoenix RDK
Operating System
Windows Server 2003
Operating System Language
Russian
Steps to Reproduce
...
allocaInstruction = Phx.IR.ValueInstruction.New( FunctionUnit, Phx.Common.Opcode.Alloca );
allocaInstruction.AppendSource( allocaSize );
FunctionUnit.LastExitInstruction.InsertBefore( allocaInstruction );
...
Actual Results
Phoenix Assertion Failure: d:\enlistments\sdk_june08\src\targets\runtimes\vccrt\win32\x86\lower.cpp, Line 199
functionUnit->HasAlloca
in (Function number 110) System.Test.MarshalingTests.StackallocTest [line 17] during Lower
in (PEModule) ..\build\Win32\Debug\BasePhoenixImage\BasePhoenixImage.exe
in (Program) <unnamed unit>
Expected Results
No assertion warnings and correct assembly output.
File Attachments
0 attachments
Sign in to post a comment.