[LLVMbugs] [Bug 14360] New: Clang with -fprofile-arcs uses lots of memory
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Fri Nov 16 07:10:43 PST 2012
http://llvm.org/bugs/show_bug.cgi?id=14360
Bug #: 14360
Summary: Clang with -fprofile-arcs uses lots of memory
Product: clang
Version: 3.1
Platform: PC
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P
Component: Frontend
AssignedTo: unassignedclangbugs at nondot.org
ReportedBy: mathias.demare at gmail.com
CC: llvmbugs at cs.uiuc.edu
Classification: Unclassified
Created attachment 9554
--> http://llvm.org/bugs/attachment.cgi?id=9554
Test case resulting in the memory issue
I noticed a memory issue when compiling our code base using Clang. The machine
running the build goes down due to excessive memory usage (with 2 GB free
memory before starting the build).
I've narrowed it down to the attached test case (it uses Google Test).
The error occurs when compiling with the following arguments:
clang -fprofile-arcs -I../gtest/include -c test.cpp -o test.o
Adding one pair of asserts adds 3 MB to the memory usage of Clang:
ASSERT_TRUE(true);
ASSERT_FALSE(false);
This is on an 64-bit Linux (Ubuntu 12.04):
clang version 3.1 (tags/RELEASE_31/final)
Target: x86_64-unknown-linux-gnu
Thread model: posix
Compiling the same test case using gcc with the same arguments: 800 MB RAM.
Compiling the same test case using gcc with '-fprofile-arcs' removed: 600 MB
RAM.
Compiling the same test case using clang with '-fprofile-arcs' removed: 300 MB
RAM.
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list