Chris Lattner wrote:> On Thu, 9 Nov 2006, Scott Michel wrote: > >> BTW: Would be nice if the frontend defined a manifest constant if it is >> generating byte code vice generating native. But that's a refinement for >> another day... > > > Why? As an end user, I'd be very unhappy if I got different code from > -emit-llvm + llc then from normal llvm-gcc.For example, I've been messing around with various high performance code in which the codebase has three versions of code in certain functions: one that uses AltiVec intrinsics, another that uses SSE[23] intrinsics, and plain ol' C code. Yes, llvm handles the intrinsics just fine but what about the case when llvm can't/won't/doesn't? Just a thought... I'm inclined to agree with you about bytecode versions, since one ought not be messing around with bytecode-specific anything. But knowing whether bytecode is being emitted could be useful. -scooter
On Thu, 9 Nov 2006, Scott Michel wrote:> BTW: Would be nice if the frontend defined a manifest constant if it is > generating byte code vice generating native. But that's a refinement for > another day...Why? As an end user, I'd be very unhappy if I got different code from -emit-llvm + llc then from normal llvm-gcc. -Chris -- http://nondot.org/sabre/ http://llvm.org/
On Thu, 9 Nov 2006, Scott Michel wrote:> For example, I've been messing around with various high performance code > in which the codebase has three versions of code in certain functions: > one that uses AltiVec intrinsics, another that uses SSE[23] intrinsics, > and plain ol' C code.ok> Yes, llvm handles the intrinsics just fine but what about the case when > llvm can't/won't/doesn't?If llvm can't handle them with -emit-llvm, it can't handle them without it. -emit-llvm is orthogonal to language/feature support.> Just a thought... I'm inclined to agree with you about bytecode > versions, since one ought not be messing around with bytecode-specific > anything. But knowing whether bytecode is being emitted could be useful.This is n detail about *how* something is being compiled, not about any code-visible feature. The best analogy is 'gcc -S x.c; as x.s' vs 'gcc -c x.c'. There is no #define available for test for -S'ness. -Chris -- http://nondot.org/sabre/ http://llvm.org/