mirror of https://github.com/openssl/openssl.git
				
				
				
			crypto/perlasm/ppc-xlate.pl: add linux64v2 flavour
This is a big endian ELFv2 configuration. ELFv2 was already being used for little endian, and big endian was traditionally ELFv1 but there are practical configurations that use ELFv2 with big endian nowadays (Adélie Linux, Void Linux, possibly Gentoo, etc.) Reviewed-by: Paul Dale <paul.dale@oracle.com> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/8883)
This commit is contained in:
		
							parent
							
								
									68a51d59a2
								
							
						
					
					
						commit
						34ab13b7d8
					
				|  | @ -49,7 +49,7 @@ my $globl = sub { | ||||||
| 	/osx/		&& do { $name = "_$name"; | 	/osx/		&& do { $name = "_$name"; | ||||||
| 				last; | 				last; | ||||||
| 			      }; | 			      }; | ||||||
| 	/linux.*(32|64le)/ | 	/linux.*(32|64(le|v2))/ | ||||||
| 			&& do {	$ret .= ".globl	$name"; | 			&& do {	$ret .= ".globl	$name"; | ||||||
| 				if (!$$type) { | 				if (!$$type) { | ||||||
| 				    $ret .= "\n.type	$name,\@function"; | 				    $ret .= "\n.type	$name,\@function"; | ||||||
|  | @ -80,7 +80,7 @@ my $globl = sub { | ||||||
| }; | }; | ||||||
| my $text = sub { | my $text = sub { | ||||||
|     my $ret = ($flavour =~ /aix/) ? ".csect\t.text[PR],7" : ".text"; |     my $ret = ($flavour =~ /aix/) ? ".csect\t.text[PR],7" : ".text"; | ||||||
|     $ret = ".abiversion	2\n".$ret	if ($flavour =~ /linux.*64le/); |     $ret = ".abiversion	2\n".$ret	if ($flavour =~ /linux.*64(le|v2)/); | ||||||
|     $ret; |     $ret; | ||||||
| }; | }; | ||||||
| my $machine = sub { | my $machine = sub { | ||||||
|  | @ -186,7 +186,7 @@ my $vmr = sub { | ||||||
| 
 | 
 | ||||||
| # Some ABIs specify vrsave, special-purpose register #256, as reserved | # Some ABIs specify vrsave, special-purpose register #256, as reserved | ||||||
| # for system use. | # for system use. | ||||||
| my $no_vrsave = ($flavour =~ /aix|linux64le/); | my $no_vrsave = ($flavour =~ /aix|linux64(le|v2)/); | ||||||
| my $mtspr = sub { | my $mtspr = sub { | ||||||
|     my ($f,$idx,$ra) = @_; |     my ($f,$idx,$ra) = @_; | ||||||
|     if ($idx == 256 && $no_vrsave) { |     if ($idx == 256 && $no_vrsave) { | ||||||
|  | @ -320,7 +320,7 @@ while($line=<>) { | ||||||
| 	if ($label) { | 	if ($label) { | ||||||
| 	    my $xlated = ($GLOBALS{$label} or $label); | 	    my $xlated = ($GLOBALS{$label} or $label); | ||||||
| 	    print "$xlated:"; | 	    print "$xlated:"; | ||||||
| 	    if ($flavour =~ /linux.*64le/) { | 	    if ($flavour =~ /linux.*64(le|v2)/) { | ||||||
| 		if ($TYPES{$label} =~ /function/) { | 		if ($TYPES{$label} =~ /function/) { | ||||||
| 		    printf "\n.localentry	%s,0\n",$xlated; | 		    printf "\n.localentry	%s,0\n",$xlated; | ||||||
| 		} | 		} | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue