Date: Wed, 27 Jan 2016 11:43:22 +0000 From: bugzilla-noreply@freebsd.org To: ruby@FreeBSD.org Subject: [Bug 206664] lang/ruby21: miniruby gets bus error on arm that requires alignment (SCTLR bit[1]==1); build fails Message-ID: <bug-206664-21402-OWEwYF4j7K@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-206664-21402@https.bugs.freebsd.org/bugzilla/> References: <bug-206664-21402@https.bugs.freebsd.org/bugzilla/>
index | next in thread | previous in thread | raw e-mail
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=206664 --- Comment #3 from Mark Millard <markmi@dsl-only.net> --- Relative to the powerpc64 segmentation faults I'll note that the powerpc64 clang does report the following sorts of warnings that means the code involved is dependent on undefined behavior that various compilers could treat differently: vm_dump.c:48:13: warning: shifting a negative signed value is undefined [-Wshift-negative-value] switch (VM_FRAME_TYPE(cfp)) { ^~~~~~~~~~~~~~~~~~ ./vm_core.h:772:43: note: expanded from macro 'VM_FRAME_TYPE' #define VM_FRAME_TYPE(cfp) ((cfp)->flag & VM_FRAME_MAGIC_MASK) ^~~~~~~~~~~~~~~~~~~ ./vm_core.h:770:36: note: expanded from macro 'VM_FRAME_MAGIC_MASK' #define VM_FRAME_MAGIC_MASK (~(~0<<VM_FRAME_MAGIC_MASK_BITS)) ~~^ . . . parse.y:1360:4: warning: shifting a negative signed value is undefined [-Wshift-negative-value] nd_set_line((yyval.node), (yyvsp[(2) - (5)].num)); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ./node.h:290:43: note: expanded from macro 'nd_set_line' RNODE(n)->flags=((RNODE(n)->flags&~(-1<<NODE_LSHIFT))|(((l)&NODE_LMASK)<<NODE_LSHIFT)) ~~^ (Many messages, just a couple extracted for here.) There were a few examples of messages like: re.c:106:11: warning: using the result of an assignment as a condition without parentheses [-Wparentheses] if (y = memmem(ys, n, xs, m)) ~~^~~~~~~~~~~~~~~~~~~~~~ but this does not get into undefined behavior. -- You are receiving this mail because: You are the assignee for the bug.help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-206664-21402-OWEwYF4j7K>
