Bug 149746 - [PATCH] devel/llvm - disable asserts by default (they appear not to be thread safe)
Summary: [PATCH] devel/llvm - disable asserts by default (they appear not to be thread...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Brooks Davis
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-08-17 19:10 UTC by Alberto Villa
Modified: 2010-09-06 23:32 UTC (History)
0 users

See Also:


Attachments
file.diff (1.95 KB, patch)
2010-08-17 19:10 UTC, Alberto Villa
no flags Details | Diff
patch-tools_clang_include_clang_Analysis_Analyses_FormatString.h (610 bytes, text/plain)
2010-08-31 08:15 UTC, c.kworr
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Alberto Villa freebsd_committer freebsd_triage 2010-08-17 19:10:06 UTC
i'll paste part of an irc log (full discussion here: https://bugzilla.redhat.com/show_bug.cgi?id=521261#c0)

[09:52] <CyrilleB> rdieter: llvm's asserts aren't thread safe, and therefore
anyone using JIT of llvm in a threaded environment will experience crash
[09:52] <CyrilleB> rdieter: the question is why would anyone want to use
asserts in a production environment :)

i can't guarantee this is correct on freebsd, but i'm the opengtl packager, and i have the same problem described in that bug report

Fix: disable asserts by default with the following patch (applies to llvm-devel too)

Patch attached with submission follows:
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2010-08-17 19:10:16 UTC
Responsible Changed
From-To: freebsd-ports-bugs->brooks

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 dfilter service freebsd_committer freebsd_triage 2010-08-30 23:55:20 UTC
brooks      2010-08-30 22:55:11 UTC

  FreeBSD ports repository

  Modified files:
    devel/llvm-devel     Makefile Makefile.svn_rev distinfo 
                         pkg-plist 
    devel/llvm-devel/files 
                           patch-tools_clang_lib_Analysis_PrintfFormatString.cpp 
                           patch-tools_clang_lib_Sema_SemaChecking.cpp 
  Removed files:
    devel/llvm-devel/files 
                           patch-tools_clang_include_clang_Analysis_Analyses_PrintfFormatString.h 
  Log:
  Upgrade to r112486.
  
  Disable asserts by default as they break threading programs.[1]
  
  PR:             ports/149746 [1]
  Submitted by:   avilla
  
  Revision  Changes    Path
  1.47      +6 -7      ports/devel/llvm-devel/Makefile
  1.17      +1 -1      ports/devel/llvm-devel/Makefile.svn_rev
  1.31      +3 -3      ports/devel/llvm-devel/distinfo
  1.2       +0 -21     ports/devel/llvm-devel/files/patch-tools_clang_include_clang_Analysis_Analyses_PrintfFormatString.h (dead)
  1.2       +3 -2      ports/devel/llvm-devel/files/patch-tools_clang_lib_Analysis_PrintfFormatString.cpp
  1.7       +3 -3      ports/devel/llvm-devel/files/patch-tools_clang_lib_Sema_SemaChecking.cpp
  1.35      +107 -42   ports/devel/llvm-devel/pkg-plist
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 3 Brooks Davis freebsd_committer freebsd_triage 2010-08-30 23:56:08 UTC
State Changed
From-To: open->closed

Committed, thanks.
Comment 4 Brooks Davis freebsd_committer freebsd_triage 2010-08-31 03:19:18 UTC
State Changed
From-To: closed->open

Closed this too soon.  Should also apply to llvm/devel.
Comment 5 c.kworr 2010-08-31 07:55:42 UTC
Hey!

Who dropped 
patch-tools_clang_include_clang_Analysis_Analyses_PrintfFormatString.h? 
The other patches in files/ depend on this one:

gmake[4]: ÐалиÑÐ°Ñ ÐºÐ°Ñалог 
"/usr/tmp/usr/ports/devel/llvm-devel/work/llvm-2.8.r112486/tools/clang/lib/Checker"
PrintfFormatString.cpp: In function 'PrintfSpecifierResult 
ParsePrintfSpecifier(clang::analyze_format_string::FormatStringHandler&, 
const char*&, const char*, unsigned int&)':
PrintfFormatString.cpp:196: error: 'bArg' is not a member of 
'clang::analyze_format_string::ConversionSpecifier'
PrintfFormatString.cpp:199: error: 'DArg' is not a member of 
'clang::analyze_format_string::ConversionSpecifier'
PrintfFormatString.cpp:207: error: 'bArg' is not a member of 
'clang::analyze_format_string::ConversionSpecifier'
PrintfFormatString.cpp:207: error: 'DArg' is not a member of 
'clang::analyze_format_string::ConversionSpecifier'
gmake[4]: *** 
[/usr/tmp/usr/ports/devel/llvm-devel/work/llvm-2.8.r112486/tools/clang/lib/Analysis/Release/PrintfFormatString.o] 
Ðомилка 1
gmake[4]: ÐалиÑÐ°Ñ ÐºÐ°Ñалог 
"/usr/tmp/usr/ports/devel/llvm-devel/work/llvm-2.8.r112486/tools/clang/lib/Analysis"
gmake[3]: *** [Analysis/.makeall] Ðомилка 2
gmake[3]: *** ÐÑÑкÑÐ²Ð°Ð½Ð½Ñ Ð·Ð°Ð²ÐµÑÑÐµÐ½Ð½Ñ Ð·Ð°Ð²Ð´Ð°Ð½Ñ...
SemaChecking.cpp: In member function 'virtual 
bool<unnamed>::CheckPrintfHandler::HandlePrintfSpecifier(const 
clang::analyze_printf::PrintfSpecifier&, const char*, unsigned int)':
SemaChecking.cpp:1515: error: 'bArg' is not a member of 
'clang::analyze_format_string::ConversionSpecifier'
SemaChecking.cpp:1515: error: 'DArg' is not a member of 
'clang::analyze_format_string::ConversionSpecifier'
SemaChecking.cpp:1522: error: 'bArg' is not a member of 
'clang::analyze_format_string::ConversionSpecifier'
gmake[4]: *** 
[/usr/tmp/usr/ports/devel/llvm-devel/work/llvm-2.8.r112486/tools/clang/lib/Sema/Release/SemaChecking.o] 
Ðомилка 1
gmake[4]: ÐалиÑÐ°Ñ ÐºÐ°Ñалог 
"/usr/tmp/usr/ports/devel/llvm-devel/work/llvm-2.8.r112486/tools/clang/lib/Sema"
gmake[3]: *** [Sema/.makeall] Ðомилка 2
gmake[3]: ÐалиÑÐ°Ñ ÐºÐ°Ñалог 
"/usr/tmp/usr/ports/devel/llvm-devel/work/llvm-2.8.r112486/tools/clang/lib"
gmake[2]: *** [all] Ðомилка 1
gmake[2]: ÐалиÑÐ°Ñ ÐºÐ°Ñалог 
"/usr/tmp/usr/ports/devel/llvm-devel/work/llvm-2.8.r112486/tools/clang"
gmake[1]: *** [clang/.makeall] Ðомилка 2
gmake[1]: ÐалиÑÐ°Ñ ÐºÐ°Ñалог 
"/usr/tmp/usr/ports/devel/llvm-devel/work/llvm-2.8.r112486/tools"
gmake: *** [all] Ðомилка 1
*** Error code 1

And those bArg and DArg were defined in removed patch. So can someone 
confirm that this ones are not needed anymore and remove all other 
patches or put this one back?

-- 
Sphinx of black quartz judge my vow.
Comment 6 c.kworr 2010-08-31 08:15:06 UTC
Here, I have taken some time to update patch so now it should look like 
this.

Tested.

-- 
Sphinx of black quartz judge my vow.
Comment 7 dfilter service freebsd_committer freebsd_triage 2010-08-31 20:04:33 UTC
brooks      2010-08-31 19:04:20 UTC

  FreeBSD ports repository

  Added files:
    devel/llvm-devel/files 
                           patch-tools_clang_include_clang_Analysis_Analyses_FormatString.h 
  Log:
  Actually add the patch to FormatString.h.
  
  PR:             ports/149746 (in error)
  Reported by:    Volodymyr Kostyrko <c.kworr@gmail.com>
  
  Revision  Changes    Path
  1.1       +16 -0     ports/devel/llvm-devel/files/patch-tools_clang_include_clang_Analysis_Analyses_FormatString.h (new)
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 8 dfilter service freebsd_committer freebsd_triage 2010-09-06 23:29:10 UTC
avilla      2010-09-06 22:28:56 UTC

  FreeBSD ports repository

  Modified files:
    devel/llvm           Makefile 
  Log:
  - Disable asserts by default as they break threading programs.
  - Bump PORTREVISION.
  
  PR:             ports/149746
  Submitted by:   avilla
  Approved by:    brooks (maintainer), tabthorpe (mentor, implicit)
  
  Revision  Changes    Path
  1.37      +5 -4      ports/devel/llvm/Makefile
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 9 Alberto Villa freebsd_committer freebsd_triage 2010-09-06 23:32:13 UTC
State Changed
From-To: open->closed

committed with the approval of brooks