NAKAMURA Takumi
af66980d8a
Fix whitespace.
...
llvm-svn: 128370
2011-03-27 01:44:40 +00:00
Kevin Enderby
d077a857cc
Remove the files for r128308 as it is causing a buildbot failure.
...
llvm-svn: 128309
2011-03-26 00:23:05 +00:00
Kevin Enderby
c8b4078654
Adding a C API to the disassembler for use by such tools as Darwin's otool(1).
...
This is a work in progress as the interface for producing symbolic operands is
not done. But a hacked prototype using information from the object file's
relocation entiries and replacing immediate operands with MCExpr's has been
shown to work with no changes to the instrucion printer. These APIs will be
moved into a dynamic library at some point.
llvm-svn: 128308
2011-03-26 00:06:33 +00:00
Daniel Dunbar
6f4c9425eb
MC: Improve some diagnostics on uses of '.' pseudo-symbol.
...
llvm-svn: 128289
2011-03-25 17:47:17 +00:00
Daniel Dunbar
3f56104be1
Tidyness.
...
llvm-svn: 128288
2011-03-25 17:47:14 +00:00
Bruno Cardoso Lopes
f170f8bff6
Add asm parsing support w/ testcases for strex/ldrex family of instructions
...
llvm-svn: 128236
2011-03-24 21:04:58 +00:00
Jim Grosbach
a3df87fb01
Clean up assembly statement separator support.
...
The MC asm lexer wasn't honoring a non-default (anything but ';') statement
separator. Fix that, and generalize a bit to support multi-character
statement separators.
llvm-svn: 128227
2011-03-24 18:46:34 +00:00
Owen Anderson
ab234158b8
Fix a bug introduced by my patch yesterday: BL is a 4-byte instructions like BLX, rather than a 2-byte instruction like B.
...
llvm-svn: 128169
2011-03-23 21:19:56 +00:00
Owen Anderson
6149a34102
RIT_ARM_ThumbBranch32Bit relocations are not used and should never be generated.
...
This fixes kimwitu++, bullet, and tramp3dv4 with the ARM integrated assembler.
Fixes <rdar://problem/9165738>.
llvm-svn: 128117
2011-03-22 22:52:54 +00:00
Owen Anderson
9746286bec
Add support for Thumb interworking addresses for symbol offsets that get constant folded very early.
...
This fixes SPASS with -integrated-as. <rdar://problem/9165399>
llvm-svn: 128037
2011-03-21 23:13:43 +00:00
Bill Wendling
00f0cddfd4
We need to pass the TargetMachine object to the InstPrinter if we are printing
...
the alias of an InstAlias instead of the thing being aliased. Because we need to
know the features that are valid for an InstAlias.
This is part of a work-in-progress.
llvm-svn: 127986
2011-03-21 04:13:46 +00:00
Rafael Espindola
1557fd6d39
Write the section table and the section data in the same order that
...
gun as does. This makes it a lot easier to compare the output of both
as the addresses are now a lot closer.
llvm-svn: 127972
2011-03-20 18:44:20 +00:00
Stuart Hastings
12d5312622
Reapply 127939 since Daniel fixed the breakage. <rdar://problem/9012638>
...
llvm-svn: 127944
2011-03-19 02:42:31 +00:00
Stuart Hastings
08b4daa191
Revert 127939. <rdar://problem/9012638>
...
llvm-svn: 127943
2011-03-19 02:33:56 +00:00
Stuart Hastings
83d4a28d1f
Revise r126127 to address Daniel's comments. <rdar://problem/9012638>
...
llvm-svn: 127939
2011-03-19 01:32:01 +00:00
Daniel Dunbar
f1d62cfc8f
MC/Mach-O: Fix regression introduced in r126127, this assignment shouldn't have
...
been removed.
llvm-svn: 127812
2011-03-17 16:25:24 +00:00
Joerg Sonnenberger
07de07eeea
Fix handling of @IDNTPOFF relocations, they need to get STT_TLS.
...
While here, add VK_ARM_TPOFF and VK_ARM_GOTTPOFF, too.
llvm-svn: 127780
2011-03-17 00:35:10 +00:00
Duncan Sands
c2631d26c0
Silence compiler warning about case values not being in the enumerated type
...
MCFixupKind. This is the same technique that is used elsewhere in MC.
llvm-svn: 127676
2011-03-15 08:54:51 +00:00
Sean Callanan
47f660aeaf
Fixed the comparison operator for the enhanced
...
disassembler's disassembler map.
llvm-svn: 127527
2011-03-12 03:27:54 +00:00
Jan Sjödin
745fc89f62
Add constructors to MCElfStreamer and MCObjectStreamer to take an extra MCAssembler * argument.
...
llvm-svn: 127343
2011-03-09 17:33:05 +00:00
Jim Grosbach
14be61aeee
Darwin 'as' silently ignores the '.ident' directive.
...
llvm-svn: 127258
2011-03-08 19:17:19 +00:00
Anton Korobeynikov
e7410dd0d5
Preliminary support for ARM frame save directives emission via MI flags.
...
This is just very first approximation how the stuff should be done
(e.g. ARM-only for now). More to follow.
llvm-svn: 127101
2011-03-05 18:43:32 +00:00
Anton Korobeynikov
a7ec2dcefd
Some first rudimentary support for ARM EHABI: print exception table in "text mode".
...
llvm-svn: 127099
2011-03-05 18:43:15 +00:00
Joerg Sonnenberger
62f759791a
Be nice to Xcore and the XMOS assembler and avoid quoting section names
...
that contain only letters, digits and the characters "_" and ".".
llvm-svn: 127028
2011-03-04 20:03:14 +00:00
Joerg Sonnenberger
852ab890b5
Bug#9033: For the ELF assembler output, always quote the section name.
...
llvm-svn: 126963
2011-03-03 22:31:08 +00:00
Jan Sjödin
771911e28b
Split MCEELFStreamer and ELFObjectWriter into .h and .cpp files, so that other components can use them.
...
llvm-svn: 126942
2011-03-03 14:52:12 +00:00
Eli Friedman
d92d17bf67
PR9352: Always emit a relocation for weak symbols. Not emitting relocations
...
for calls to weak symbols with a definition has the appearance of working
with LLVM-generated code because weak symbol definitions are put in their
own sections.
llvm-svn: 126933
2011-03-03 07:24:36 +00:00
Oscar Fuentes
98a3c80a3e
Fixes warnings emitted by Visual Studio 2010 compiler.
...
Patch by Erik Olofsson!
llvm-svn: 126796
2011-03-01 23:11:57 +00:00
Jan Sjödin
30a52dec93
Make all static functions become static class methods. Move shared (duplicated) functions to new MCELF class.
...
llvm-svn: 126686
2011-02-28 21:45:04 +00:00
Cameron Zwarich
fcf51fd298
Roll out r126425 and r126450 to see if it fixes the failures on the buildbots.
...
llvm-svn: 126488
2011-02-25 16:30:32 +00:00
Joerg Sonnenberger
afb36fad99
Restore r125595 (reverted in r126336) with modifications:
...
Introduce a variable in the AsmParserExtension whether [] is valid in an
expression. If it is true, parse them like (). Enable this for ELF only.
llvm-svn: 126443
2011-02-24 21:59:22 +00:00
Devang Patel
b037383a35
Enable DebugInfo support for COFF object files.
...
Patch by Nathan Jeffords!
llvm-svn: 126425
2011-02-24 21:04:00 +00:00
Benjamin Kramer
c053644217
Plug some leaks in edis.
...
- Don't leak parsed operands during tokenization.
- Don't leak printed insts in llvm-mc.
llvm-svn: 126381
2011-02-24 11:03:19 +00:00
Jim Grosbach
0c03a3a146
Revert r125595, which is an X86-only undocumented assembly syntax extension
...
enabled for all targets. Non-X86 targets should not have this behavior
enabled by default.
Joerg, if you would like to resubmit with the behavior conditionalized to be
X86-ELF only, that's fine.
llvm-svn: 126336
2011-02-23 21:26:51 +00:00
Rafael Espindola
9e18e96264
Put in the symbol table symbols only used in a .globl statement.
...
Fixes PR9292.
llvm-svn: 126330
2011-02-23 20:22:07 +00:00
Sean Callanan
34770edf43
Fixed a bug in the enhanced disassembler that caused
...
it to ignore valid uses of FS and GS as additional
base registers in address computations. Added a test
case for this.
llvm-svn: 126302
2011-02-23 03:31:28 +00:00
Stuart Hastings
bf83659d11
Omit private_extern declarations of extern symbols; followup to
...
r124468. Patch by Rafael Avila de Espindola!
llvm-svn: 126297
2011-02-23 02:27:05 +00:00
Joerg Sonnenberger
4f864d3111
Bug#9172: Don't use static in file scope, use an attribute on the
...
parser.
llvm-svn: 126225
2011-02-22 16:53:11 +00:00
Joerg Sonnenberger
37d5484d18
Handle FK_PCRel_1 and add a test case for this and FK_PCRel_4.
...
llvm-svn: 126157
2011-02-21 23:25:41 +00:00
Stuart Hastings
d7927e0fcd
End the line if we return early. Radar 9012638.
...
llvm-svn: 126141
2011-02-21 21:07:07 +00:00
Stuart Hastings
b4863a41e9
Fix to correctly support attribute((section("__DATA, __common"))).
...
Radar 9012638.
llvm-svn: 126127
2011-02-21 17:27:17 +00:00
Joerg Sonnenberger
eef2f9009d
Use a vector of pairs to implement the section stack, not two
...
independent vectors.
llvm-svn: 126099
2011-02-21 01:07:42 +00:00
Rafael Espindola
f849bf81bd
Add some limited support for labels in org directives. Hopefully enough to fix
...
PR9245.
llvm-svn: 126091
2011-02-20 20:20:07 +00:00
Oscar Fuentes
5ed962656c
Move library stuff out of the toplevel CMakeLists.txt file.
...
llvm-svn: 125968
2011-02-18 22:06:14 +00:00
Rafael Espindola
490d02a334
Gas is very inconsistent about when a relaxation/relocation is needed. Do
...
the right thing and stop trying to copy it. Fixes PR8944.
llvm-svn: 125648
2011-02-16 03:25:55 +00:00
Rafael Espindola
58ac6e1677
Add support for pushsection and popsection. Patch by Joerg Sonnenberger.
...
llvm-svn: 125629
2011-02-16 01:08:29 +00:00
Roman Divacky
4e0f4957bc
Add support for parsing [expr].
...
This is submitted by Joerg Sonnenberger and fixes his PR8685.
llvm-svn: 125595
2011-02-15 20:43:39 +00:00
Rafael Espindola
70d8015063
Switch llvm to using comdats. For now always use groups with a single
...
section.
llvm-svn: 125526
2011-02-14 22:23:49 +00:00
Rafael Espindola
85bc995c5b
Move broken HasCommonSymbols to ELFWriter.cpp.
...
llvm-svn: 125490
2011-02-14 16:51:08 +00:00
Jim Grosbach
01af6c4641
More whitespace cleanup...
...
llvm-svn: 125388
2011-02-11 19:05:56 +00:00