History log of /external/clang/lib/Lex/MacroArgs.h
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
a08529cc3f00e0b47a3c028823634129ac46847b 03-Oct-2011 Abramo Bagnara <abramo.bagnara@gmail.com> Fixed exapnsion range for # and ##.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141012 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Lex/MacroArgs.h
d7bb6a014afec8c8e2962d8282db412e664dc2f9 22-Sep-2011 David Blaikie <dblaikie@gmail.com> ArrayRef-ifying MacroArgs::create's arguments argument.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140288 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Lex/MacroArgs.h
b73377eeb3eff76be134203aebb6068244b177f3 07-Jul-2011 Argyrios Kyrtzidis <akyrtzi@gmail.com> Make the Preprocessor more memory efficient and improve macro instantiation diagnostics.

When a macro instantiation occurs, reserve a SLocEntry chunk with length the
full length of the macro definition source. Set the spelling location of this chunk
to point to the start of the macro definition and any tokens that are lexed directly
from the macro definition will get a location from this chunk with the appropriate offset.

For any tokens that come from argument expansion, '##' paste operator, etc. have their
instantiation location point at the appropriate place in the instantiated macro definition
(the argument identifier and the '##' token respectively).
This improves macro instantiation diagnostics:

Before:

t.c:5:9: error: invalid operands to binary expression ('struct S' and 'int')
int y = M(/);
^~~~
t.c:5:11: note: instantiated from:
int y = M(/);
^

After:

t.c:5:9: error: invalid operands to binary expression ('struct S' and 'int')
int y = M(/);
^~~~
t.c:3:20: note: instantiated from:
\#define M(op) (foo op 3);
~~~ ^ ~
t.c:5:11: note: instantiated from:
int y = M(/);
^

The memory savings for a candidate boost library that abuses the preprocessor are:

- 32% less SLocEntries (37M -> 25M)
- 30% reduction in PCH file size (900M -> 635M)
- 50% reduction in memory usage for the SLocEntry table (1.6G -> 800M)

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@134587 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Lex/MacroArgs.h
f5809a7b76fd5a86ae737d9b525a1eddb9339ee7 28-Dec-2009 Chris Lattner <sabre@nondot.org> The PreExpArgTokens array is indexed with an argument #,
not a token number. Fix the reserve logic to get the right
amount of space.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92202 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Lex/MacroArgs.h
23f77e59718385512984d4e2a021bef52b9f6ddf 15-Dec-2009 Chris Lattner <sabre@nondot.org> set up the machinery for a MacroArgs cache hanging off Preprocessor.
We creating and free thousands of MacroArgs objects (and the related
std::vectors hanging off them) for the testcase in PR5610 even though
there are only ~20 live at a time. This doesn't actually use the
cache yet.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91391 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Lex/MacroArgs.h
561395bead16b9dc9b0d5bfb6b257a9ed4545db6 14-Dec-2009 Chris Lattner <sabre@nondot.org> move the VarargsElided member of MacrosArgs to shrink the MacroArgs struct
on 64-bit targets. Pass Preprocessor into create/destroy methods of MacroArgs
even though it isn't used yet.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91345 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Lex/MacroArgs.h
1eb4433ac451dc16f4133a88af2d002ac26c58ef 09-Sep-2009 Mike Stump <mrs@apple.com> Remove tabs, and whitespace cleanups.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81346 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Lex/MacroArgs.h
bda0b626e74513950405c27525af87e214e605e2 16-Mar-2008 Chris Lattner <sabre@nondot.org> Make a major restructuring of the clang tree: introduce a top-level
lib dir and move all the libraries into it. This follows the main
llvm tree, and allows the libraries to be built in parallel. The
top level now enforces that all the libs are built before Driver,
but we don't care what order the libs are built in. This speeds
up parallel builds, particularly incremental ones.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@48402 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/Lex/MacroArgs.h