-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
golang-1.15 (1.15~rc1-1) unstable; urgency=medium [ Shengjing Zhu ] * Backport patches to fix the FPU ABI problems for mips32 https://go-review.googlesource.com/c/go/+/237058/ [ Dr. Tobias Quathamer ] * New upstream version 1.15~rc1 - Refresh patches - net/http: Expect 100-continue panics in httputil.ReverseProxy. See golang/go#34902, fixes CVE-2020-15586
- Loading branch information
Showing
203 changed files
with
8,342 additions
and
5,276 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -563,6 +563,7 @@ Hitoshi Mitake <[email protected]> | |
Holden Huang <[email protected]> | ||
Hong Ruiqi <[email protected]> | ||
Hongfei Tan <[email protected]> | ||
Hootsuite Inc. | ||
Hsin-Ho Yeh <[email protected]> | ||
Hu Keping <[email protected]> | ||
Hugues Bruant <[email protected]> | ||
|
@@ -934,7 +935,7 @@ Maya Rashish <[email protected]> | |
Mayank Kumar <[email protected]> | ||
MediaMath, Inc | ||
Meir Fischer <[email protected]> | ||
Meng Zhuo <[email protected]> | ||
Meng Zhuo <[email protected]> <[email protected]> | ||
Meteor Development Group | ||
Mhd Sulhan <[email protected]> | ||
Micah Stetson <[email protected]> | ||
|
@@ -1044,6 +1045,7 @@ Niels Widger <[email protected]> | |
Nigel Kerr <[email protected]> | ||
Nik Nyby <[email protected]> | ||
Nikhil Benesch <[email protected]> | ||
Nikita Gillmann <[email protected]> <[email protected]> | ||
Niklas Schnelle <[email protected]> | ||
Niko Dziemba <[email protected]> | ||
Nikolay Turpitko <[email protected]> | ||
|
@@ -1397,6 +1399,7 @@ Upthere, Inc. | |
Uriel Mangado <[email protected]> | ||
Vadim Grek <[email protected]> | ||
Vadim Vygonets <[email protected]> | ||
Vee Zhang <[email protected]> <[email protected]> | ||
Vendasta | ||
Veselkov Konstantin <[email protected]> | ||
Victor Vrantchan <[email protected]> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1303,6 +1303,7 @@ Kshitij Saraogi <[email protected]> | |
Kun Li <[email protected]> | ||
Kunpei Sakai <[email protected]> | ||
Kuntal Majumder <[email protected]> | ||
Kush Patel <[email protected]> | ||
Kyle Consalus <[email protected]> | ||
Kyle Isom <[email protected]> | ||
Kyle Jones <[email protected]> | ||
|
@@ -1501,7 +1502,7 @@ Maxwell Krohn <[email protected]> | |
Maya Rashish <[email protected]> | ||
Mayank Kumar <[email protected]> | ||
Meir Fischer <[email protected]> | ||
Meng Zhuo <[email protected]> | ||
Meng Zhuo <[email protected]> <[email protected]> | ||
Mhd Sulhan <[email protected]> | ||
Micah Stetson <[email protected]> | ||
Michael Anthony Knyszek <[email protected]> | ||
|
@@ -1654,6 +1655,7 @@ Nigel Kerr <[email protected]> | |
Nigel Tao <[email protected]> | ||
Nik Nyby <[email protected]> | ||
Nikhil Benesch <[email protected]> | ||
Nikita Gillmann <[email protected]> <[email protected]> | ||
Nikita Kryuchkov <[email protected]> | ||
Nikita Vanyasin <[email protected]> | ||
Niklas Schnelle <[email protected]> | ||
|
@@ -2195,6 +2197,7 @@ Vadim Grek <[email protected]> | |
Vadim Vygonets <[email protected]> | ||
Val Polouchkine <[email protected]> | ||
Valentin Vidic <[email protected]> | ||
Vee Zhang <[email protected]> <[email protected]> | ||
Vega Garcia Luis Alfonso <[email protected]> | ||
Venil Noronha <[email protected]> | ||
Veselkov Konstantin <[email protected]> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
go1.15beta1 | ||
go1.15rc1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,17 @@ | ||
golang-1.15 (1.15~rc1-1) unstable; urgency=medium | ||
|
||
[ Shengjing Zhu ] | ||
* Backport patches to fix the FPU ABI problems for mips32 | ||
https://go-review.googlesource.com/c/go/+/237058/ | ||
|
||
[ Dr. Tobias Quathamer ] | ||
* New upstream version 1.15~rc1 | ||
- Refresh patches | ||
- net/http: Expect 100-continue panics in httputil.ReverseProxy. | ||
See https://github.com/golang/go/issues/34902, fixes CVE-2020-15586 | ||
|
||
-- Dr. Tobias Quathamer <[email protected]> Mon, 03 Aug 2020 21:22:44 +0200 | ||
|
||
golang-1.15 (1.15~beta1-2) unstable; urgency=medium | ||
|
||
* Source-only upload. | ||
|
106 changes: 106 additions & 0 deletions
106
debian/patches/0003-cmd-go-cmd-cgo-pass-mfp32-and-mhard-soft-float-to-MI.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,106 @@ | ||
From: YunQiang Su <[email protected]> | ||
Date: Tue, 9 Jun 2020 04:09:58 +0000 | ||
Subject: cmd/go, cmd/cgo: pass -mfp32 and -mhard/soft-float to MIPS GCC | ||
|
||
For mips32 currently, we are using FP32, while the gcc may be FPXX, | ||
which may generate .MIPS.abiflags and .gnu.attributes section with | ||
value as FPXX. So the kernel will treat the exe as FPXX, and may | ||
choose to use FR=1 FPU mode for it. | ||
Currently, in Go, we use 2 lwc1 to load both half of a double value | ||
to a pair of even-odd FPR. This behavior can only work with FR=0 mode. | ||
|
||
In FR=1 mode, all of 32 FPR are 64bit. If we lwc1 the high-half of a double | ||
value to an odd FPR, and try to use the previous even FPR to compute, the | ||
real high-half of even FPR will be unpredicatable. | ||
We set -mfp32 to force the gcc generate FP32 code and section value. | ||
|
||
More details about FP32/FPXX/FP64 are explained in: | ||
https://web.archive.org/web/20180828210612/https://dmz-portal.mips.com/wiki/MIPS_O32_ABI_-_FR0_and_FR1_Interlinking | ||
|
||
When GOMIPS/GOMIPS64 is set as softfloat, we should also pass | ||
-msoft-float to gcc. | ||
|
||
Here we also add -mno-odd-spreg option, since Loongson's CPU cannot use | ||
odd-number FR in FR=0 mode. | ||
|
||
Fixes #39435 | ||
|
||
Change-Id: I54026ad416a815fe43a9261ebf6d02e5519c3930 | ||
--- | ||
src/cmd/cgo/gcc.go | 12 ++++++++++-- | ||
src/cmd/cgo/main.go | 4 +++- | ||
src/cmd/go/internal/work/exec.go | 14 ++++++++++++-- | ||
3 files changed, 25 insertions(+), 5 deletions(-) | ||
|
||
diff --git a/src/cmd/cgo/gcc.go b/src/cmd/cgo/gcc.go | ||
index a59534e..d1bdee8 100644 | ||
--- a/src/cmd/cgo/gcc.go | ||
+++ b/src/cmd/cgo/gcc.go | ||
@@ -1548,9 +1548,17 @@ func (p *Package) gccMachine() []string { | ||
case "s390x": | ||
return []string{"-m64"} | ||
case "mips64", "mips64le": | ||
- return []string{"-mabi=64"} | ||
+ if gomips64 == "hardfloat" { | ||
+ return []string{"-mabi=64", "-mhard-float"} | ||
+ } else if gomips64 == "softfloat" { | ||
+ return []string{"-mabi=64", "-msoft-float"} | ||
+ } | ||
case "mips", "mipsle": | ||
- return []string{"-mabi=32"} | ||
+ if gomips == "hardfloat" { | ||
+ return []string{"-mabi=32", "-mfp32", "-mhard-float", "-mno-odd-spreg"} | ||
+ } else if gomips == "softfloat" { | ||
+ return []string{"-mabi=32", "-msoft-float"} | ||
+ } | ||
} | ||
return nil | ||
} | ||
diff --git a/src/cmd/cgo/main.go b/src/cmd/cgo/main.go | ||
index 5a7bb3f..e0fede8 100644 | ||
--- a/src/cmd/cgo/main.go | ||
+++ b/src/cmd/cgo/main.go | ||
@@ -227,7 +227,7 @@ var gccgoMangleCheckDone bool | ||
var gccgoNewmanglingInEffect bool | ||
var importRuntimeCgo = flag.Bool("import_runtime_cgo", true, "import runtime/cgo in generated code") | ||
var importSyscall = flag.Bool("import_syscall", true, "import syscall in generated code") | ||
-var goarch, goos string | ||
+var goarch, goos, gomips, gomips64 string | ||
|
||
func main() { | ||
objabi.AddVersionFlag() // -V | ||
@@ -376,6 +376,8 @@ func newPackage(args []string) *Package { | ||
if s := os.Getenv("GOOS"); s != "" { | ||
goos = s | ||
} | ||
+ gomips = objabi.GOMIPS | ||
+ gomips64 = objabi.GOMIPS64 | ||
ptrSize := ptrSizeMap[goarch] | ||
if ptrSize == 0 { | ||
fatalf("unknown ptrSize for $GOARCH %q", goarch) | ||
diff --git a/src/cmd/go/internal/work/exec.go b/src/cmd/go/internal/work/exec.go | ||
index 071c9d2..347a060 100644 | ||
--- a/src/cmd/go/internal/work/exec.go | ||
+++ b/src/cmd/go/internal/work/exec.go | ||
@@ -2488,9 +2488,19 @@ func (b *Builder) gccArchArgs() []string { | ||
case "s390x": | ||
return []string{"-m64", "-march=z196"} | ||
case "mips64", "mips64le": | ||
- return []string{"-mabi=64"} | ||
+ args := []string{"-mabi=64"} | ||
+ if cfg.GOMIPS64 == "hardfloat" { | ||
+ return append(args, "-mhard-float") | ||
+ } else if cfg.GOMIPS64 == "softfloat" { | ||
+ return append(args, "-msoft-float") | ||
+ } | ||
case "mips", "mipsle": | ||
- return []string{"-mabi=32", "-march=mips32"} | ||
+ args := []string{"-mabi=32", "-march=mips32"} | ||
+ if cfg.GOMIPS == "hardfloat" { | ||
+ return append(args, "-mhard-float", "-mfp32", "-mno-odd-spreg") | ||
+ } else if cfg.GOMIPS == "softfloat" { | ||
+ return append(args, "-msoft-float") | ||
+ } | ||
case "ppc64": | ||
if cfg.Goos == "aix" { | ||
return []string{"-maix64"} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
0001-Disable-test-for-UserHomeDir.patch | ||
0002-Fix-Lintian-warnings-about-wrong-interpreter-path.patch | ||
0003-cmd-go-cmd-cgo-pass-mfp32-and-mhard-soft-float-to-MI.patch |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -79,15 +79,13 @@ <h2 id="Releases">Releases</h2> | |
<h2 id="Source_code">Source code</h2> | ||
|
||
<p> | ||
If you cannot use a release, or prefer to build gccgo for | ||
yourself, | ||
the gccgo source code is accessible via Subversion. The | ||
GCC web site | ||
has <a href="https://gcc.gnu.org/svn.html">instructions for getting the | ||
GCC source code</a>. The gccgo source code is included. As a | ||
convenience, a stable version of the Go support is available in | ||
a branch of the main GCC code | ||
repository: <code>svn://gcc.gnu.org/svn/gcc/branches/gccgo</code>. | ||
If you cannot use a release, or prefer to build gccgo for yourself, the | ||
gccgo source code is accessible via Git. The GCC web site has | ||
<a href="https://gcc.gnu.org/git.html">instructions for getting the GCC | ||
source code</a>. The gccgo source code is included. As a convenience, a | ||
stable version of the Go support is available in the | ||
<code>devel/gccgo</code> branch of the main GCC code repository: | ||
<code>git://gcc.gnu.org/git/gcc.git</code>. | ||
This branch is periodically updated with stable Go compiler sources. | ||
</p> | ||
|
||
|
@@ -139,13 +137,10 @@ <h3 id="Gold">Gold</h3> | |
</p> | ||
|
||
<pre> | ||
cvs -z 9 -d :pserver:[email protected]:/cvs/src login | ||
[password is "anoncvs"] | ||
[The next command will create a directory named src, not binutils] | ||
cvs -z 9 -d :pserver:[email protected]:/cvs/src co binutils | ||
git clone git://sourceware.org/git/binutils-gdb.git | ||
mkdir binutils-objdir | ||
cd binutils-objdir | ||
../src/configure --enable-gold=default --prefix=/opt/gold | ||
../binutils-gdb/configure --enable-gold=default --prefix=/opt/gold | ||
make | ||
make install | ||
</pre> | ||
|
@@ -176,7 +171,7 @@ <h3 id="Build_commands">Build commands</h3> | |
</p> | ||
|
||
<pre> | ||
svn checkout svn://gcc.gnu.org/svn/gcc/branches/gccgo gccgo | ||
git clone --branch devel/gccgo git://gcc.gnu.org/git/gcc.git gccgo | ||
mkdir objdir | ||
cd objdir | ||
../gccgo/configure --prefix=/opt/gccgo --enable-languages=c,c++,go --with-ld=/opt/gold/bin/ld | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.