[LLVMdev] FW: question about malloc call vs. instruction
Vikram S. Adve
vadve at cs.uiuc.edu
Wed Sep 11 10:08:01 PDT 2002
I'm forwarding this question to llvmdev:
-----Original Message-----
From: lee white baugh [mailto:leebaugh at students.uiuc.edu]
Sent: Wednesday, September 11, 2002 1:27 AM
To: Vikram S. Adve
Subject: RE: mp1
i'll attempt to address the issues i raised in my long email as i am able.
as i said i have figured out the worklist thing, and am happy to report
that i've negotiated lots of troubles compiling and so on and am actually
printing out a bunch of instructions. which reveals my new problem: when
i attempt a malloc in my own, it comes out like this:
%reg216 = call int (...)* %malloc( ulong 8 ) ; <int> [#uses=1]
a call to malloc, not a malloc instruction. i don't know how to get the
information i need out of a call to malloc.
when i replace 'malloc' in the code with 'alloca', i get
%reg107 = alloca ubyte, uint 8 ; <ubyte*> [#uses=1]
so everything is fine for alloca.
i thought if i ran the inline pass it might change a malloc call to a
malloc instruction, but it didn't. can you tell me what's up here?
i'm really sorry to constantly bug you. if you hate it let me know. my
motivation in doing so is to get through this as quickly as i can so i can
return to qual studying!
lee
<pre>
+------+
+-+ o+---\ /
+--+ The *-
++ Hamster +--/ \
>-------------<
this living hand, now warm and capable
of earnest grasping, would, if it were cold
and in the icy silence of the tomb,
so haunt thy days and chill thy dreaming nights
that thou wouldst wish thine own heart dry of blood
so in my veins red life might stream again,
and thou be conscience-calmed -- see here it is --
i hold it towards you.
: john keats
</pre>
More information about the llvm-dev
mailing list