[llvm-bugs] [Bug 25535] New: Programs compiled with optimization and profiling crash
via llvm-bugs
llvm-bugs at lists.llvm.org
Sun Nov 15 01:34:29 PST 2015
https://llvm.org/bugs/show_bug.cgi?id=25535
Bug ID: 25535
Summary: Programs compiled with optimization and profiling
crash
Product: clang
Version: unspecified
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: Driver
Assignee: unassignedclangbugs at nondot.org
Reporter: sisnkemp at gmail.com
CC: llvm-bugs at lists.llvm.org
Classification: Unclassified
When using profiling (option -pg) in combination with optimizations (e.g. -O3),
compiled programs crash in the profiling routine mcount().
This is because mcount (on x86_64 at least) relies on the frame pointer to be
valid. When optimizations are enabled, however, the frame pointer is
eliminated.
A test case that demonstrates this and a proposed diff to fix this is given at:
http://reviews.llvm.org/D14215
The key is to disable frame-pointer elimination in the driver and the frontend
when the profiling option is provided.
--
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/20151115/0f211c79/attachment-0001.html>
More information about the llvm-bugs
mailing list