[llvm-dev] Regarding Usage of opt
Chengnian Sun via llvm-dev
llvm-dev at lists.llvm.org
Mon Mar 7 00:40:00 PST 2016
Hi All,
I run into another problem with "opt-trunk -loop-data-prefetch". The pass
is in Transforms/Scalar/LoopDataPrefetch.cpp. How to avoid the following
assertion failure, or I should just avoiding using this pass in isolation?
Thank you.
=============================================================
$: opt-trunk -loop-data-prefetch t.c_000.bc -o temp.bc
opt-trunk:
/tmp/llvm-builder/llvm-source-trunk/lib/Transforms/Scalar/LoopDataPrefetch.cpp:102:
virtual bool {anonymous}::LoopDataPrefetch::runOnFunction(llvm::Function&):
Assertion `TTI->getCacheLineSize() && "Cache line size is not set for
target"' failed.
0 opt-trunk 0x00000000018249b5
llvm::sys::PrintStackTrace(llvm::raw_ostream&) + 37
1 opt-trunk 0x0000000001822946 llvm::sys::RunSignalHandlers() + 54
2 opt-trunk 0x0000000001822b64
3 libpthread.so.0 0x00007f6b3f3e1340
4 libc.so.6 0x00007f6b3e5ffcc9 gsignal + 57
5 libc.so.6 0x00007f6b3e6030d8 abort + 328
6 libc.so.6 0x00007f6b3e5f8b86
7 libc.so.6 0x00007f6b3e5f8c32
8 opt-trunk 0x00000000016d9e1c
9 opt-trunk 0x00000000014877e3
llvm::FPPassManager::runOnFunction(llvm::Function&) + 643
10 opt-trunk 0x0000000001487e2b
llvm::legacy::PassManagerImpl::run(llvm::Module&) + 619
11 opt-trunk 0x00000000006f9ce9 main + 7353
12 libc.so.6 0x00007f6b3e5eaec5 __libc_start_main + 245
13 opt-trunk 0x0000000000738368
Stack dump:
0. Program arguments: opt-trunk -loop-data-prefetch t.c_000.bc -o
temp.bc
1. Running pass 'Function Pass Manager' on module 't.c_000.bc'.
2. Running pass 'Loop Data Prefetch' on function '@main'
Aborted (core dumped)
$:
On Fri, Mar 4, 2016 at 12:44 AM, Chengnian Sun <chengniansun at gmail.com>
wrote:
> Hi,
>
> I am new to llvm, and recently am playing with opt. I want to use opt to
> apply one optimization pass to a .bc file. However, I encounter some
> problems which I failed to find the answers on the internet. Any
> suggestions are highly appreciated.
>
> Question 1:
>
> For example, I issued the following command
>
> $: opt-trunk -si-lower-control-flow t.c_00.bc -o t.c_01.bc
>
> Then I got the following error,
>
> -------------------------------------------------------------- Error Start
> --------------------------------------------------------------
>
> Pass 'SI Lower control flow pseudo instructions' is not initialized.
>
> Verify if there is a pass dependency cycle.
>
> Required Passes:
>
> opt-trunk:
> /tmp/llvm-builder/llvm-source-trunk/lib/IR/LegacyPassManager.cpp:668: void
> llvm::PMTopLevelManager::schedulePass(llvm::Pass*): Assertion `PI &&
> "Expected required passes to be initialized"' failed.
>
> -------------------------------------------------------------- Error End
> --------------------------------------------------------------
>
> Question 2:
>
> Some passes depend on other dependencies. Is there any convenient way to
> get the dependency for a specific pass?
>
> Thank you and best regards,
>
> Chengnian.
>
--
Best Regards.
Chengnian SUN.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20160307/b88d623a/attachment.html>
More information about the llvm-dev
mailing list