search for: ftrapv

Displaying 20 results from an estimated 63 matches for "ftrapv".

2020 Jun 11
2
pointer subtraciton on arm for 8.3p1
...lchain. I found that spamming connection attempts sometimes causes aborts in sshd. Upon getting this up in gdb I found that the pointer subtraction inside openbsd-compat/{strlcat.c,strlcpy.c} (and maybe elsewhere) causes the 32 bit pointer difference to wrap which triggers the abort because of the -ftrapv option. This example illustrates the problem, I get an abort when I compile for 32 bit arm. > #include <stdio.h> > int main(int argc, char** argv) { > char* src = (char*)0x7ffffec0; > char* s = (char*)0x80000049; > printf("%ld\n",s - src); > retur...
2017 Sep 23
3
Call for testing: OpenSSH 7.6
> Portable OpenSSH is also available via [...] Github: https://github.com/openssh/openssh-portable > > Running the regression tests supplied with Portable OpenSSH does not require installation and is a simply: > > $ ./configure && make tests I was going to try this on Kali Linux (latest version), but ran into trouble right away. No "configure" script exists
2018 Jun 08
2
vanilla build of 7.7p1 release on linux/4.17 fails with gcc8 @ "/usr/bin/ld: unrecognized option '-Wl,-z,retpolineplt'"
On Thu, Jun 07, 2018 at 06:14:42PM -0700, PGNet Dev wrote: > On 6/7/18 6:08 PM, Darren Tucker wrote: > > Well the intent is you should be able to set CC and LD to whatever you > > want as long as they work. In this case, the OSSH_CHECK_LDFLAG_LINK > > test invokes autoconf's AC_LINK_IFELSE with uses CC not LD. I'm not > > sure what to do about it yet though. I
2018 Jun 07
2
vanilla build of 7.7p1 release on linux/4.17 fails with gcc8 @ "/usr/bin/ld: unrecognized option '-Wl,-z,retpolineplt'"
...nu Compiler: /usr/bin/gcc-8 Compiler flags: -g -O2 -pipe -Wall -Wpointer-arith -Wuninitialized -Wsign-compare -Wformat-security -Wsizeof-pointer-memaccess -Wno-pointer-sign -Wno-unused-result -fno-strict-aliasing -mfunction-return=thunk -mindirect-branch=thunk -D_FORTIFY_SOURCE=2 -ftrapv -fno-builtin-memset -fstack-protector-strong -fPIE Preprocessor flags: -D_XOPEN_SOURCE=600 -D_BSD_SOURCE -D_DEFAULT_SOURCE Linker flags: -Wl,-z,retpolineplt -Wl,-z,relro -Wl,-z,now -Wl,-z,noexecstack -fstack-protector-strong -pie Libraries: -lutil -lz -lcrypt -lresolv repor...
2008 Aug 22
7
[LLVMdev] Dependence Analysis [was: Flow-Sensitive AA]
...like a lot of real-world software that is using LLVM already doesn't seem to be affected by the lack of them. Does anyone know of any C/C++ programs that require integer overflow on signed arithmetic (even though it is not strictly allowed by the standard)? Also, does anyone know how -ftrapv is implemented on processors that don't have hardware detection of integer overflow? It sounds very expensive to do entirely in software. Thanks, --Vikram Associate Professor, Computer Science University of Illinois at Urbana-Champaign http://llvm.org/~vadve On Aug 22, 2008, at 3:50...
2019 Apr 01
2
Call for testing: OpenSSH 8.0 [AIX Fail]
...oded), "%s%s%c%s", HASH_MAGIC, uu_salt, not sure yet. . > gcc -O2 -mcpu=powerpc -D_LINUX_SOURCE_COMPAT -pipe -Wall -Wpointer-arith -Wuninitialized -Wsign-compare -Wformat-security -Wsizeof-pointer-memaccess -Wno-pointer-sign -Wno-unused-result -fno-strict-aliasing -D_FORTIFY_SOURCE=2 -ftrapv -fno-builtin-memset -I. -I. -I/opt/freeware/include -I/opt/phs/include -DSSHDIR=\"/usr/local/etc\" -D_PATH_SSH_PROGRAM=\"/usr/local/bin/ssh\" -D_PATH_SSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ssh-askpass\" -D_PATH_SFTP_SERVER=\"/usr/local/libexec/sftp-server\&quo...
2008 Aug 22
0
[LLVMdev] Dependence Analysis [was: Flow-Sensitive AA]
...of overflow are permitted. For example, if the compiler gets an overflow when doing arithmetic on constants, the overflowed value can still be used with - fwrapv, but not otherwise. The -fstrict-overflow option is enabled at levels -O2, - O3, -Os. -ftrapv This option generates traps for signed overflow on addition, subtraction, multiplication operations. -fwrapv This option instructs the compiler to assume that signed arithmetic overflow of addition, subtraction and multiplication wraps ar...
2011 Jun 13
0
[LLVMdev] Is LLVM expressive enough to represent asynchronous exceptions?
On Jun 13, 2011, at 2:12 PM, Andrew Trick wrote: > Although I believe asynchronous signals are also best handled by the runtime. They can be converted into cooperative exceptions. I have to say I can't see the value in resuming from an interrupt at literally any instruction address. For what it's worth, SEH (which inspires a lot of this) allows blocks of code to be protected from
2012 Aug 13
0
[LLVMdev] [cfe-dev] [RFC] Extending and improving Clang's undefined behavior checking
...10, 2012, at 7:48 PM, Richard Smith wrote: > Hi, > > There are three different (and mostly orthogonal, design-wise) areas where I would like to make improvements to Clang's undefined behavior checking: > > 1) Completeness of checks. There are integer undefined behaviors which -ftrapv and -fcatch-undefined-behavior don't catch, and there is almost no checking available for any other undefined behaviors outside of those and the ones caught by {Address,Thread,Memory} Sanitizer. > > I would like to add support for checking the following additional undefined behaviors, wh...
2016 Aug 02
6
OpenSSH 7.3p1 can't be build on Solaris 10
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 With this change built ok. But patch must be quite different on my platform (see attached) for portable version. And, of course, after autoreconf run. 02.08.2016 10:55, Darren Tucker ?????: > --- a/configure.ac > +++ b/configure.ac > @@ -754,6 +754,9 @@ main() { if (NSVersionOfRunTimeLibrary("System") >= (60 << 16))
2016 Jul 14
2
Error when compiling openssh-7.2p2
...p_filter Host: x86_64-unknown-linux-gnu Compiler: gcc Compiler flags: -g -O2 -Wall -Wpointer-arith -Wuninitialized -Wsign-compare -Wformat-security -Wsizeof-pointer-memaccess -Wno-pointer-sign -Wno-unused-result -fno-strict-aliasing -D_FORTIFY_SOURCE=2 -ftrapv -fno-builtin-memset -fstack-protector-all -fPIE Preprocessor flags: Linker flags: -Wl,-z,relro -Wl,-z,now -Wl,-z,noexecstack -fstack-protector-all -pie Libraries: -lcrypto -ldl -lutil -lz -lcrypt -lresolv make .. gcc -g -O2 -Wall -Wpointer-arith -Wuninitial...
2010 Aug 10
0
[LLVMdev] Overflow trap
...gt; > Which alternative should I pursue? The third is obviously the easiest for me, but other LLVM users would benefit from the other two. > > I don't understand... why can't you use a branch on a llvm.sadd.with.overflow that goes to an llvm.trap? This is what clang does with -ftrapv. -Chris -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20100809/c3ec1ffd/attachment.html>
2016 Aug 24
6
[Bug 2608] New: Signed overflow in openbsd-compat/strlcpy.c
...ugzilla.mindrot.org/attachment.cgi?id=2866&action=edit test driver of strlcpy to demo the bug. Pointer arithmatic results in implementation defined signed integer type, so that 's - src' in strlcpy and others may trigger signed overflow. When the code is compiled by gcc or clang with -ftrapv option, the overflow would lead to program abort. $ gcc test.c strlcpy.c -o test -m32 -ftrapv $ ./test Allocating src starting from 0x7fffff40 Trying to copy 0x400 from 0x7fffff40 to 0x9630008 Aborted (core dumped) The proposed fix is also attached. -- You ar...
2017 Feb 03
2
compilation errors on master
...ribe' says V_7_3_P1-207-gc924b2ef (shouldn't it say V_7_4_P1-<yadayada>?). This is what I see: gcc -g -O2 -Wall -Wpointer-arith -Wuninitialized -Wsign-compare -Wformat-security -Wsizeof-pointer-memaccess -Wno-pointer-sign -Wno-unused-result -fno-strict-aliasing -D_FORTIFY_SOURCE=2 -ftrapv -fno-builtin-memset -fstack-protector-strong -fPIE -I. -I. -DSSHDIR=\"/usr/local/etc\" -D_PATH_SSH_PROGRAM=\"/usr/local/bin/ssh\" -D_PATH_SSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ssh-askpass\" -D_PATH_SFTP_SERVER=\"/usr/local/libexec/sftp-server\" -D_PATH_S...
2017 Oct 03
2
Change in optimisation with UB in mind
...defined as trapping (which is a valid implementation of undefined behaviour). In LLVM, this would be represented as using the overflow-checking add intrinsic followed by a branch to a trap in the overflow case. The back end should then lower this to a trapping add instruction. Clang already has -ftrapv that implements almost this behaviour. David -------------------------------------------------------------- Intel Research and Development Ireland Limited Registered in Ireland Registered Office: Collinstown Industrial Park, Leixlip, County Kildare Registered Number: 308263 This e-mail and any...
2017 Jun 29
2
The undef story
...or no additional value. > > The current project is not based in evidence, I have asked for any SPEC benchmark > that shows performance gain by the compiler taking advantage of “undefined behavior” > and no one can show that. > > One easy way to measure this is to enable -fwrapv/-ftrapv on the compiler command line, which impede the compiler's usual exploitation of signed wrap UB in C. Last I heard, those options lead to substantial performance regressions. > In my other emails I point out that Dan achieved the goal of hoisting sign-extension out of loops for LP64 targets...
2010 Aug 09
2
[LLVMdev] Overflow trap
Several instruction set architectures include arithmetic operations that can trap on overflow, or support this feature with a separate trap-on-overflow-flag instruction (such as the x86 INTO instruction). I am adding a back-end to the Open Dylan compiler to generate LLVM IR. The original back-end, which generates x86 machine code, makes use of the INTO instruction, and the runtime turns the
2018 Jan 19
2
openssh build failure on High Sierra (10.13.2)
...der-High-Sierra gcc 6.4 fails to build openssh 7.6p1 (or the latest SNAP) with: /usr/local/gcc-6.3.0/bin/gcc -g -O2 -pipe -Wall -Wpointer-arith -Wuninitialized -Wsign-compare -Wformat-security -Wsizeof-pointer-memaccess -Wno-pointer-sign -Wno-unused-result -fno-strict-aliasing -D_FORTIFY_SOURCE=2 -ftrapv -fno-builtin-memset -fstack-protector-strong -I. -I. -I/usr/local/sshssl102n/include -DSSHDIR=\"/usr/local/ssh/etc\" -D_PATH_SSH_PROGRAM=\"/usr/local/ssh/bin/ssh\" -D_PATH_SSH_ASKPASS_DEFAULT=\"/usr/local/ssh/libexec/ssh-askpass\" -D_PATH_SFTP_SERVER=\"/usr/loca...
2011 Jun 13
3
[LLVMdev] Is LLVM expressive enough to represent asynchronous exceptions?
On Jun 12, 2011, at 5:53 PM, John McCall wrote: > > On Jun 12, 2011, at 5:31 PM, Sohail Somani wrote: > >> On 11-06-12 7:40 PM, John McCall wrote: >>> On Jun 12, 2011, at 2:14 PM, Cameron Zwarich wrote: >>> >>>>> On Jun 12, 2011, at 1:25 AM, Duncan Sands wrote: >>>>> >>>>>>> Hi Sohail,
2010 Aug 10
2
[LLVMdev] Overflow trap
...ternative should I pursue? The third is obviously the easiest for me, but other LLVM users would benefit from the other two. >> >> > > I don't understand... why can't you use a branch on a llvm.sadd.with.overflow that goes to an llvm.trap? This is what clang does with -ftrapv. > > -Chris -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20100809/edc30562/attachment.html>