diff options
author | andreas <andreas@FreeBSD.org> | 1996-12-20 15:27:41 +0800 |
---|---|---|
committer | andreas <andreas@FreeBSD.org> | 1996-12-20 15:27:41 +0800 |
commit | 9df99c05cab7e9489d8b325a945f6a3b9a53f5b8 (patch) | |
tree | 68f31cbcb2ad8eb709db0c97b5da53e738e47e8d /lang/pgcc | |
parent | e9075e68ca30f2ef4ce164abcd17a3405ce54c2b (diff) | |
download | freebsd-ports-gnome-9df99c05cab7e9489d8b325a945f6a3b9a53f5b8.tar.gz freebsd-ports-gnome-9df99c05cab7e9489d8b325a945f6a3b9a53f5b8.tar.zst freebsd-ports-gnome-9df99c05cab7e9489d8b325a945f6a3b9a53f5b8.zip |
Bootstrap pgcc-current using -O instead of -O2 (for safety reasons, I don't
want higher optimization levels result in unsafer binaries).
Fix bug, that causes core dumps when using higher optimization levels
than -O2.
Results with dhrystone 2.1 (1000000 loops):
stock cc (2.7.2.1 from current) : 136k (136xxx)
pgcc-current with -O2 : 138k
pgcc-current with -O6 : 172k
And no coredump anymore. Reason for coredump:
With -O3 cc1 does an register-to-register-copy optimization and it tries
to write some debugging information about what it is doing into a file
that does not exist unless you have instructed cc1 to dump all its
information about its internal state. (From: Sascha Blank)
BTW: PLIST is really coming soon, it's on my todo list ;-)
BTW2: Is Sascha already in the contributors list ? Have to go to work now.
Submitted by: Sascha Blank <blank@sliphost37.uni-trier.de>
Diffstat (limited to 'lang/pgcc')
-rw-r--r-- | lang/pgcc/files/patch-ab | 2 | ||||
-rw-r--r-- | lang/pgcc/files/patch-ac | 19 |
2 files changed, 20 insertions, 1 deletions
diff --git a/lang/pgcc/files/patch-ab b/lang/pgcc/files/patch-ab index 32aa00bc552e..69bdb147b7a5 100644 --- a/lang/pgcc/files/patch-ab +++ b/lang/pgcc/files/patch-ab @@ -5,7 +5,7 @@ XCFLAGS = TCFLAGS = -CFLAGS = -g -+CFLAGS = -pipe -O2 ++CFLAGS = -pipe -O BOOT_CFLAGS = -O $(CFLAGS) # These exists to be overridden by the x-* and t-* files, respectively. X_CFLAGS = diff --git a/lang/pgcc/files/patch-ac b/lang/pgcc/files/patch-ac new file mode 100644 index 000000000000..399793d43109 --- /dev/null +++ b/lang/pgcc/files/patch-ac @@ -0,0 +1,19 @@ +*** toplev.c.orig Mon Dec 2 16:30:20 1996 +--- toplev.c Mon Dec 2 16:30:37 1996 +*************** +*** 3387,3393 **** + }); + + /* intel1 */ +! if(optimize > 0 && flag_reg_reg_copy_opt) + { + reg_to_reg_copy_opt(insns, global_reg_dump_file); + } +--- 3387,3393 ---- + }); + + /* intel1 */ +! if(optimize > 0 && flag_reg_reg_copy_opt && global_reg_dump) + { + reg_to_reg_copy_opt(insns, global_reg_dump_file); + } |