[llvm-commits] [llvm] r76982 - in /llvm/trunk: include/llvm/Transforms/IPO/InlinerPass.h lib/Transforms/IPO/Inliner.cpp lib/Transforms/Scalar/DeadStoreElimination.cpp lib/Transforms/Scalar/JumpThreading.cpp lib/Transforms/Scalar/SimplifyHalfPowrL
Chris Lattner
clattner at apple.com
Fri Jul 24 11:49:31 PDT 2009
On Jul 24, 2009, at 11:41 AM, Eli Friedman wrote:
> On Fri, Jul 24, 2009 at 11:28 AM, Duncan Sands<baldrick at free.fr>
> wrote:
>> Hi Dan,
>>
>>> Convert several more passes to use
>>> getAnalysisIfAvailable<TargetData>()
>>> instead of getAnalysis<TargetData>().
>>>
>>> Modified:
>>> llvm/trunk/include/llvm/Transforms/IPO/InlinerPass.h
>>> llvm/trunk/lib/Transforms/IPO/Inliner.cpp
>>> llvm/trunk/lib/Transforms/Scalar/DeadStoreElimination.cpp
>>> llvm/trunk/lib/Transforms/Scalar/JumpThreading.cpp
>>> llvm/trunk/lib/Transforms/Scalar/SimplifyHalfPowrLibCalls.cpp
>>
>> suppose I have some bitcode that contains target data in it.
>> If I run "opt -inline" on it, will the target information be
>> used? Since the inliner no longer requires target data, maybe
>> the TargetData pass won't be run at all, causing
>> getAnalysisIfAvailable<TargetData>() to return NULL, and
>> target data not to be used even though present in the bitcode.
>
> AFAIK, opt will unconditionally add TargetData, whether or not a
> target is specified in the bitcode file.
Once all passes use TargetData only if available, this can be fixed.
-Chris
More information about the llvm-commits
mailing list