summaryrefslogtreecommitdiff
path: root/src/math/abs_power64x.s
blob: 3ba8201b3be048923cdbc53481b40d867fe6ec34 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// Copyright 2011 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.

// +build power64 power64le

#include "textflag.h"

TEXT ·Abs(SB),NOSPLIT,$0-16
	MOVD	x+0(FP), R3
	MOVD 	$((1<<63)-1), R4
	AND	R4, R3
	MOVD	R3, ret+8(FP)
	RETURN