Bug 216166 - graphics/gegl3: clang 4.0 crashes during build (3 ports skipped)
Summary: graphics/gegl3: clang 4.0 crashes during build (3 ports skipped)
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: i386 Any
: --- Affects Only Me
Assignee: Dimitry Andric
URL: https://llvm.org/bugs/show_bug.cgi?id...
Keywords: needs-patch
Depends on:
Blocks: 216008
  Show dependency treegraph
 
Reported: 2017-01-17 08:47 UTC by Jan Beich
Modified: 2017-01-23 00:12 UTC (History)
1 user (show)

See Also:


Attachments
gegl/buffer/gegl-sampler-nohalo.c (preprocessed, compressed) (198.25 KB, application/x-xz)
2017-01-17 16:55 UTC, Jan Beich
no flags Details
command line args (for cc as clang 4.0) (4.32 KB, text/plain)
2017-01-17 16:56 UTC, Jan Beich
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Beich freebsd_committer 2017-01-17 08:47:29 UTC
Assertion failed: ((TLI.getTypeAction(*DAG.getContext(), Op.getValueType()) == TargetLowering::TypeLegal || TLI.isTypeLegal(Op.getValueType()) || Op.getOpcode() == ISD::TargetConstant) && "Unexpected illegal type!"), function LegalizeOp, file /usr/src/contrib/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp, line 921.
cc: error: unable to execute command: Abort trap
cc: error: clang frontend command failed due to signal (use -v to see invocation)
FreeBSD clang version 4.0.0 (branches/release_40 292009) (based on LLVM 4.0.0)
Target: i386-unknown-freebsd12.0

build log: http://sprunge.us/eAMU
Comment 1 Jan Beich freebsd_committer 2017-01-17 16:55:06 UTC
Created attachment 178998 [details]
gegl/buffer/gegl-sampler-nohalo.c (preprocessed, compressed)
Comment 2 Jan Beich freebsd_committer 2017-01-17 16:56:13 UTC
Created attachment 178999 [details]
command line args (for cc as clang 4.0)
Comment 3 Jan Beich freebsd_committer 2017-01-17 16:58:49 UTC
Can you reproduce on /projects/clang400-import@312309 or devel/llvm-devel after editing .sh file?
Comment 4 Dimitry Andric freebsd_committer 2017-01-17 18:30:04 UTC
(In reply to Jan Beich (mail not working) from comment #3)
> Can you reproduce on /projects/clang400-import@312309 or devel/llvm-devel
> after editing .sh file?

Yes, I can reproduce with clang 4.0.0 (branches/release_40 292009) (as in the clang400-import branch).  Investigating...
Comment 5 Dimitry Andric freebsd_committer 2017-01-17 19:23:32 UTC
Minimized a test case, and submitted it upstream as https://llvm.org/bugs/show_bug.cgi?id=31672
Comment 6 commit-hook freebsd_committer 2017-01-22 18:32:11 UTC
A commit references this bug:

Author: dim
Date: Sun Jan 22 18:31:49 UTC 2017
New revision: 312643
URL: https://svnweb.freebsd.org/changeset/base/312643

Log:
  Pull in r292758 from upstream llvm trunk (by Sanjay Patel):

    [x86] avoid crashing with illegal vector type (PR31672)

    https://llvm.org/bugs/show_bug.cgi?id=31672

  This fixes an assertion while building graphics/gegl3.

  PR:		216166

Changes:
  projects/clang400-import/contrib/llvm/lib/Target/X86/X86ISelLowering.cpp
Comment 7 Dimitry Andric freebsd_committer 2017-01-22 19:45:05 UTC
After r312643, I can build graphics/gegl to completion now, with the SIMD option checked.
Comment 8 Jan Beich freebsd_committer 2017-01-23 00:12:04 UTC
graphics/gegl3, like graphics/svgalib, is a blocker for x11/gnome3 metaport. It doesn't have SIMD option unlike graphics/gegl. Anyway, gegl3 builds fine now: http://sprunge.us/NPdF