This consists of ~2000 lines of amd64 assembly and a, much slower, generic Go version in curve25519.go. The assembly has been ported from djb's public domain sources and the only semantic alterations are to deal with Go's split stacks. R=rsc CC=golang-dev https://golang.org/cl/5786045
19 lines
561 B
ArmAsm
19 lines
561 B
ArmAsm
// Copyright 2012 The Go Authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style
|
|
// license that can be found in the LICENSE file.
|
|
|
|
// This code was translated into a form compatible with 6a from the public
|
|
// domain sources in SUPERCOP: http://bench.cr.yp.to/supercop.html
|
|
|
|
DATA ·REDMASK51(SB)/8, $0x0007FFFFFFFFFFFF
|
|
GLOBL ·REDMASK51(SB), $8
|
|
|
|
DATA ·_121666_213(SB)/8, $996687872
|
|
GLOBL ·_121666_213(SB), $8
|
|
|
|
DATA ·_2P0(SB)/8, $0xFFFFFFFFFFFDA
|
|
GLOBL ·_2P0(SB), $8
|
|
|
|
DATA ·_2P1234(SB)/8, $0xFFFFFFFFFFFFE
|
|
GLOBL ·_2P1234(SB), $8
|