John McCall
2adddcae7e
Remove abstract expression kinds from the StmtClass enum. Update a few users
...
appropriately. Call out a few missing cases in the expression mangler.
llvm-svn: 95176
2010-02-03 00:55:45 +00:00
Chris Lattner
dee74e2805
make these less sensitive to asm verbose changes by disabling it for them.
...
llvm-svn: 95175
2010-02-03 00:48:53 +00:00
Dale Johannesen
55e768c99a
Print FPImm a less kludgy way; APFloat.toString seems
...
to have some problems anyway.
llvm-svn: 95171
2010-02-03 00:36:40 +00:00
Bob Wilson
76e8c59509
Fix some comment typos.
...
llvm-svn: 95170
2010-02-03 00:33:21 +00:00
Fariborz Jahanian
e165191990
Simplify setting of DeclContext for @catch variable
...
(per Doug's comment).
llvm-svn: 95169
2010-02-03 00:32:51 +00:00
Chris Lattner
249453fff0
pass an instprinter into the AsmPrinter if it is available.
...
llvm-svn: 95168
2010-02-03 00:29:55 +00:00
Douglas Gregor
b92a1565c3
Implement the lvalue-to-rvalue conversion where needed. The
...
lvalue-to-rvalue conversion adjusts lvalues of qualified, non-class
type to rvalue expressions of the unqualified variant of that
type. For example, given:
const int i;
(void)(i + 17);
the lvalue-to-rvalue conversion for the subexpression "i" will turn it
from an lvalue expression (a DeclRefExpr) with type 'const int' into
an rvalue expression with type 'int'. Both C and C++ mandate this
conversion, and somehow we've slid through without implementing it.
We now have both DefaultFunctionArrayConversion and
DefaultFunctionArrayLvalueConversion, and which gets used depends on
whether we do the lvalue-to-rvalue conversion or not. Generally, we do
the lvalue-to-rvalue conversion, but there are a few notable
exceptions:
- the left-hand side of a '.' operator
- the left-hand side of an assignment
- a C++ throw expression
- a subscript expression that's subscripting a vector
Making this change exposed two issues with blocks:
- we were deducing const-qualified return types of non-class type
from a block return, which doesn't fit well
- we weren't always setting the known return type of a block when it
was provided with the ^return-type syntax
Fixes the current Clang-on-Clang compile failure and PR6076.
llvm-svn: 95167
2010-02-03 00:27:59 +00:00
Chris Lattner
d111bd518d
make any use of the "O" stream in asmprinter print to
...
stderr if in filetype=obj mode. This is a hack, and will
live until dwarf emission and other random stuff that is
not yet going through MCStreamer is upgraded. It only
impacts filetype=obj mode.
llvm-svn: 95166
2010-02-03 00:22:02 +00:00
Eric Christopher
d86233c118
Recommit this, looks like it wasn't the cause.
...
llvm-svn: 95165
2010-02-03 00:21:58 +00:00
Fariborz Jahanian
08d614d92e
Fix DeclContext of an objective-c @catch variable
...
declaration. Fixes radar 7590273.
llvm-svn: 95164
2010-02-03 00:01:43 +00:00
Evan Cheng
5f238a9650
ByVal frame object size should be that of the byval argument, not the size of the type which is just a pointer. This is not known to break stuff but is wrong nevertheless.
...
llvm-svn: 95163
2010-02-02 23:58:13 +00:00
Chris Lattner
8856a67e41
Hook up -filetype=obj through the MachO streamer. Here's a demo:
...
$ cat t.ll
@g = global i32 42
$ llc t.ll -o t.o -filetype=obj
$ nm t.o
00000000 D _g
There is still a ton of work left. Instructions are not being encoded
yet apparently.
llvm-svn: 95162
2010-02-02 23:57:42 +00:00
Jim Grosbach
d0a2f52f8f
As of r79039, we still try to eliminate the frame pointer on leaf functions,
...
even when -disable-fp-elim is specified.
llvm-svn: 95161
2010-02-02 23:56:14 +00:00
Evan Cheng
6f36a083ef
Revert 95130.
...
llvm-svn: 95160
2010-02-02 23:55:14 +00:00
Dale Johannesen
b3cfc2b77c
Accept floating point immediates in DEBUG_VALUE.
...
llvm-svn: 95159
2010-02-02 23:54:23 +00:00
Daniel Dunbar
bdbffbedf0
AsmParser/X86: Add temporary hack to allow parsing "sal". Eventually we need
...
some mechanism for specifying alternative syntaxes, but I'm not sure what form
that should take yet.
llvm-svn: 95158
2010-02-02 23:46:47 +00:00
Daniel Dunbar
3b8a4663b9
AsmMatcherEmitter: Use stable_sort when reordering instructions, so that order
...
is still deterministic even amongst ambiguous instructions (eventually ambiguous
match orders will be a hard error, but we aren't there yet).
llvm-svn: 95157
2010-02-02 23:46:36 +00:00
Chris Lattner
c49f8c7456
use OwningPtr and factor code better.
...
llvm-svn: 95156
2010-02-02 23:45:17 +00:00
Chris Lattner
b0d44c3807
refactor code so that LLVMTargetMachine creates the asmstreamer and
...
mccontext instead of having AsmPrinter do it. This allows other
types of MCStreamer's to be passed in.
llvm-svn: 95155
2010-02-02 23:37:42 +00:00
Eric Christopher
e67d01a9a8
Hopefully temporarily revert this.
...
llvm-svn: 95154
2010-02-02 23:01:31 +00:00
Chris Lattner
530c72a65d
simplify getVerboseAsm
...
llvm-svn: 95153
2010-02-02 22:58:13 +00:00
Chris Lattner
32445d300f
move handling of asm-verbose out of AsmPrinter.cpp into LLVMTargetMachine.cpp with the rest of the command line options.
...
llvm-svn: 95152
2010-02-02 22:54:51 +00:00
Ted Kremenek
b251eb6901
Remove RegionStoreSubRegionMap::iterator and RegionStoreSubRegionMap::begin_end(). This is a precursor to using DenseSet to represent region sets instead of ImmutableSet.
...
llvm-svn: 95151
2010-02-02 22:38:47 +00:00
Chris Lattner
f8928453bc
remove dead #include, stupid symlinks.
...
llvm-svn: 95150
2010-02-02 22:37:42 +00:00
Chris Lattner
73051044fd
remove the # TAILCALL markers, which was causing the to fail.
...
It's unclear if the matcher is nondeterminstic of what here,
but I'm getting matches without TAILCALL and some other hosts
are getting matches with it.
llvm-svn: 95149
2010-02-02 22:36:29 +00:00
Chris Lattner
919b97436e
Remove a bunch of stuff around the edges of the ELF writer.
...
Now the only use of the ELF writer is the JIT, which won't be
easy to fix in the short term. :( :(
llvm-svn: 95148
2010-02-02 22:31:11 +00:00
Eric Christopher
f9553572b7
Reformat my last patch slightly.
...
llvm-svn: 95147
2010-02-02 22:29:26 +00:00
Chris Lattner
f46359642f
tidy some targets.
...
llvm-svn: 95146
2010-02-02 22:13:21 +00:00
Eric Christopher
4264e7e46f
Re-add strcmp and known size object size checking optimization.
...
Passed bootstrap and nightly test run here.
llvm-svn: 95145
2010-02-02 22:10:43 +00:00
Chris Lattner
6a6137832d
remove dead code.
...
llvm-svn: 95144
2010-02-02 22:03:00 +00:00
Daniel Dunbar
09d81caa12
MCAssembler/Darwin: Add a test (on Darwin) that we assemble a bunch of
...
instructions exactly like 'as', and produce equivalent .o files.
llvm-svn: 95143
2010-02-02 22:00:15 +00:00
Chris Lattner
308acc4ab0
detemplatize the ppc code emitter.
...
llvm-svn: 95142
2010-02-02 21:55:58 +00:00
Chris Lattner
a3fa43932d
remove dead code.
...
llvm-svn: 95141
2010-02-02 21:52:03 +00:00
Chris Lattner
e8565d8eaf
add a definition for ID.
...
llvm-svn: 95140
2010-02-02 21:49:29 +00:00
Chris Lattner
8d806876c0
detemplatize ARM code emitter.
...
llvm-svn: 95138
2010-02-02 21:48:51 +00:00
Daniel Dunbar
3184f22447
MCAsmParser/X86: Represent absolute memory operands as CodeGen does, with scale
...
== 1.
llvm-svn: 95137
2010-02-02 21:44:16 +00:00
Daniel Dunbar
d28d6db735
MCCodeEmitter/X86: Handle tied registers better when converting MCInst ->
...
MCMachineInstr. This also fixes handling of tied registers for MRMSrcMem
instructions.
llvm-svn: 95136
2010-02-02 21:44:10 +00:00
Daniel Dunbar
255a8c8b13
MC/Mach-O: Set SOME_INSTRUCTIONS bit for sections.
...
llvm-svn: 95135
2010-02-02 21:44:01 +00:00
Chris Lattner
c83cfb9dfa
remove dead code.
...
llvm-svn: 95134
2010-02-02 21:38:59 +00:00
Chris Lattner
4578098b97
detemplatize alpha code emission, it is now JIT specific.
...
llvm-svn: 95133
2010-02-02 21:35:47 +00:00
Nick Kledzik
debb901045
add __sync_synchronize. Needed by compiler when emitting thumb1 with -fno-builtin
...
llvm-svn: 95132
2010-02-02 21:34:04 +00:00
Chris Lattner
0cd6c2a047
eliminate all the dead addSimpleCodeEmitter implementations.
...
eliminate random "code emitter" stuff in Alpha, except for
the JIT path. Next up, remove the template cruft.
llvm-svn: 95131
2010-02-02 21:31:47 +00:00
Evan Cheng
c1b0116ff1
Pass callsite return type to TargetLowering::LowerCall and use that to check sibcall eligibility.
...
llvm-svn: 95130
2010-02-02 21:29:10 +00:00
Ted Kremenek
416b923786
Explicitly check for casts to double or complex types instead of possibly asserting in SValuator.
...
llvm-svn: 95128
2010-02-02 21:11:40 +00:00
Dan Gohman
47d7347858
Make DenseSet's erase pass on the return value rather than swallowing it.
...
llvm-svn: 95127
2010-02-02 21:11:22 +00:00
Dan Gohman
6013cf9cbe
Fix function names in comments. Thanks Duncan!
...
llvm-svn: 95126
2010-02-02 21:10:27 +00:00
Chris Lattner
60272554aa
update for llvm api changes.
...
llvm-svn: 95125
2010-02-02 21:06:50 +00:00
Chris Lattner
f0cb12acf2
eliminate FileModel::Model, just use CodeGenFileType. The client
...
of the code generator shouldn't care what object format a target
uses.
llvm-svn: 95124
2010-02-02 21:06:45 +00:00
Nick Kledzik
1683cebc9d
add compiler options for B&I builds
...
llvm-svn: 95123
2010-02-02 21:03:34 +00:00
Chris Lattner
de9b3ada5d
this apparently depends on the host somehow.
...
llvm-svn: 95122
2010-02-02 20:57:28 +00:00