summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2011-08-18 04:41:58 +0000
committerDouglas Gregor <dgregor@apple.com>2011-08-18 04:41:58 +0000
commit914eb7c18a8124302c249230f12431d4c7fde7e7 (patch)
treea8c14b9d5ddb1bd8e1473e88680f75121861105a /llvm/lib/Transforms
parentdf0c151ba67535d21fdf12e4a0d249b88d506ea1 (diff)
downloadbcm5719-llvm-914eb7c18a8124302c249230f12431d4c7fde7e7.tar.gz
bcm5719-llvm-914eb7c18a8124302c249230f12431d4c7fde7e7.zip
Teach ModuleManager::addModule() to check whether a particular module
has already been loaded before allocating a new Module structure. If the module has already been loaded (uniquing based on file name), then just return the existing module rather than trying to load it again. This allows us to load a DAG of modules. Introduce a simple test case that forms a diamond-shaped module graph, and illustrates that a source file importing the bottom of the diamond can see declarations in all four of the modules that make up the diamond. llvm-svn: 137925
Diffstat (limited to 'llvm/lib/Transforms')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud