[LLVMbugs] [Bug 21653] New: [REGRESSION] Crash in llvm::formLCSSA
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Mon Nov 24 06:17:55 PST 2014
http://llvm.org/bugs/show_bug.cgi?id=21653
Bug ID: 21653
Summary: [REGRESSION] Crash in llvm::formLCSSA
Product: clang
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: -New Bugs
Assignee: unassignedclangbugs at nondot.org
Reporter: ismail at donmez.ws
CC: llvmbugs at cs.uiuc.edu
Classification: Unclassified
Produced with clang r222646 on Linux x86-64.
> clang -c -O2 testcase.i
testcase.i:16:20: warning: implicit declaration of function 'av_mallocz' is
invalid in C99 [-Wimplicit-function-declaration]
HEVCPPS *pps = av_mallocz(sizeof(*pps));
^
testcase.i:16:14: warning: incompatible integer to pointer conversion
initializing 'HEVCPPS *' (aka 'struct HEVCPPS *') with an
expression of type 'int' [-Wint-conversion]
HEVCPPS *pps = av_mallocz(sizeof(*pps));
^ ~~~~~~~~~~~~~~~~~~~~~~~~
testcase.i:29:1: warning: control reaches end of non-void function
[-Wreturn-type]
}
^
#0 0x7fbe45b9c03a llvm::sys::PrintStackTrace(_IO_FILE*)
(/opt/clang/lib64/libLLVMSupport.so+0xb603a)
#1 0x7fbe45b9d4ab (/opt/clang/lib64/libLLVMSupport.so+0xb74ab)
#2 0x7fbe4410d170 __restore_rt (/lib64/libc.so.6+0x35170)
#3 0x7fbe45859e38 llvm::formLCSSA(llvm::Loop&, llvm::DominatorTree&,
llvm::ScalarEvolution*) (/opt/clang/lib64/libLLVMTransformUtils.so+0x4fe38)
#4 0x7fbe4585a2d8 llvm::formLCSSARecursively(llvm::Loop&, llvm::DominatorTree&,
llvm::ScalarEvolution*) (/opt/clang/lib64/libLLVMTransformUtils.so+0x502d8)
#5 0x7fbe4585a2be llvm::formLCSSARecursively(llvm::Loop&, llvm::DominatorTree&,
llvm::ScalarEvolution*) (/opt/clang/lib64/libLLVMTransformUtils.so+0x502be)
#6 0x7fbe4585a2be llvm::formLCSSARecursively(llvm::Loop&, llvm::DominatorTree&,
llvm::ScalarEvolution*) (/opt/clang/lib64/libLLVMTransformUtils.so+0x502be)
#7 0x7fbe4585a6f8 (/opt/clang/lib64/libLLVMTransformUtils.so+0x506f8)
#8 0x7fbe475a33b3 llvm::FPPassManager::runOnFunction(llvm::Function&)
(/opt/clang/lib64/libLLVMCore.so+0x17b3b3)
#9 0x7fbe4720a2fd (/opt/clang/lib64/libLLVMipa.so+0xf2fd)
#10 0x7fbe475a3b57 llvm::legacy::PassManagerImpl::run(llvm::Module&)
(/opt/clang/lib64/libLLVMCore.so+0x17bb57)
#11 0x7fbe3eb23063 clang::EmitBackendOutput(clang::DiagnosticsEngine&,
clang::CodeGenOptions const&, clang::TargetOptions const&, clang::LangOptions
const&, llvm::StringRef, llvm::Module*, clang::BackendAction,
llvm::raw_ostream*) (/opt/clang/lib64/libclangCodeGen.so+0x60063)
#12 0x7fbe3ec67c4a (/opt/clang/lib64/libclangCodeGen.so+0x1a4c4a)
#13 0x7fbe3fdcd073 clang::ParseAST(clang::Sema&, bool, bool)
(/opt/clang/lib64/libclangParse.so+0x2a073)
#14 0x7fbe44c2b4de clang::FrontendAction::Execute()
(/opt/clang/lib64/libclangFrontend.so+0xa74de)
#15 0x7fbe44bfe51c
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&)
(/opt/clang/lib64/libclangFrontend.so+0x7a51c)
#16 0x7fbe449821b5 clang::ExecuteCompilerInvocation(clang::CompilerInstance*)
(/opt/clang/lib64/libclangFrontendTool.so+0x31b5)
#17 0x40f3d3 cc1_main(llvm::ArrayRef<char const*>, char const*, void*)
(/opt/clang/bin/clang-3.6+0x40f3d3)
#18 0x40da94 main (/opt/clang/bin/clang-3.6+0x40da94)
#19 0x7fbe440f9b45 __libc_start_main (/lib64/libc.so.6+0x21b45)
#20 0x40add9 _start (/opt/clang/bin/clang-3.6+0x40add9)
Stack dump:
0. Program arguments: /opt/clang/bin/clang-3.6 -cc1 -triple
x86_64-suse-linux -emit-obj -disable-free -main-file-name testcase.i
-mrelocation-model static -mthread-model posix -fmath-errno -masm-verbose
-mconstructor-aliases -munwind-tables -fuse-init-array -target-cpu x86-64
-momit-leaf-frame-pointer -dwarf-column-info -coverage-file
/havana/t/i/delta-2006.08.03/testcase.i -resource-dir
/opt/clang/bin/../lib64/clang/3.6.0 -O2 -std=c11 -fdebug-compilation-dir
/havana/t/i/delta-2006.08.03 -ferror-limit 19 -fmessage-length 132
-mstackrealign -fobjc-runtime=gcc -fdiagnostics-show-option -fcolor-diagnostics
-vectorize-loops -vectorize-slp -o testcase.o -x cpp-output testcase.i
1. <eof> parser at end of file
2. Per-module optimization passes
3. Running pass 'CallGraph Pass Manager' on module 'testcase.i'.
4. Running pass 'Loop-Closed SSA Form Pass' on function
'@ff_hevc_decode_nal_pps'
clang-3.6: error: unable to execute command: Segmentation fault
clang-3.6: error: clang frontend command failed due to signal (use -v to see
invocation)
clang version 3.6.0 (trunk 222646)
Target: x86_64-suse-linux
Thread model: posix
clang-3.6: note: diagnostic msg: PLEASE submit a bug report to
http://llvm.org/bugs/ and include the crash backtrace, preprocessed source, and
associated run script.
clang-3.6: note: diagnostic msg: Error generating preprocessed source(s) - no
preprocessable inputs.
> cat testcase.i
typedef struct HEVCWindow {
unsigned int log2_min_tb_size;
unsigned int log2_ctb_size;
int min_tb_width;
int min_tb_height;
} HEVCSPS;
typedef struct HEVCPPS {
int *ctb_addr_rs_to_ts;
int *min_tb_addr_zs;
} HEVCPPS;
int ff_hevc_decode_nal_pps()
{
HEVCSPS *sps = 0;
int log2_diff_ctb_min_tb_size;
int i, j, x, y, ctb_addr_rs, tile_id;
HEVCPPS *pps = av_mallocz(sizeof(*pps));
log2_diff_ctb_min_tb_size = sps->log2_ctb_size - sps->log2_min_tb_size;
for (y = 0; y < sps->min_tb_height; y++) {
for (x = 0; x < sps->min_tb_width; x++) {
int val = pps->ctb_addr_rs_to_ts[ctb_addr_rs] <<
(log2_diff_ctb_min_tb_size * 2);
for (i = 0; i < log2_diff_ctb_min_tb_size; i++) {
int m = 1 << i;
val += (m & x ? m * m : 0) + (m & y ? 2 * m * m : 0);
}
pps->min_tb_addr_zs[y * sps->min_tb_width + x] = val;
}
}
}
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20141124/417b39e6/attachment.html>
More information about the llvm-bugs
mailing list