1*4db555a5SRichard Lowe/*
2*4db555a5SRichard Lowe * This file and its contents are supplied under the terms of the
3*4db555a5SRichard Lowe * Common Development and Distribution License ("CDDL"), version 1.0.
4*4db555a5SRichard Lowe * You may only use this file in accordance with the terms of version
5*4db555a5SRichard Lowe * 1.0 of the CDDL.
6*4db555a5SRichard Lowe *
7*4db555a5SRichard Lowe * A full copy of the text of the CDDL should have accompanied this
8*4db555a5SRichard Lowe * source.  A copy of the CDDL is also available via the Internet at
9*4db555a5SRichard Lowe * http://www.illumos.org/license/CDDL.
10*4db555a5SRichard Lowe */
11*4db555a5SRichard Lowe
12*4db555a5SRichard Lowe/*
13*4db555a5SRichard Lowe * Copyright 2012, Richard Lowe.
14*4db555a5SRichard Lowe */
15*4db555a5SRichard Lowe
16*4db555a5SRichard Lowe	.section	.rodata.str1.1,"aMS",@progbits,1
17*4db555a5SRichard Lowe.LC0:
18*4db555a5SRichard Lowe	.string	"foo: %p\n"
19*4db555a5SRichard Lowe	.text
20*4db555a5SRichard Lowe.globl main
21*4db555a5SRichard Lowe	.type	main, @function
22*4db555a5SRichard Lowemain:
23*4db555a5SRichard Lowe.LFB0:
24*4db555a5SRichard Lowe	pushq	%rbp
25*4db555a5SRichard Lowe.LCFI0:
26*4db555a5SRichard Lowe	movq	%rsp, %rbp
27*4db555a5SRichard Lowe.LCFI1:
28*4db555a5SRichard Lowe	movq	foo@GOTTPOFF(%rip), %r12
29*4db555a5SRichard Lowe	addq	%fs:0, %r12
30*4db555a5SRichard Lowe        movq    %r12, %rsi
31*4db555a5SRichard Lowe	movl	$.LC0, %edi
32*4db555a5SRichard Lowe	movl	$0, %eax
33*4db555a5SRichard Lowe	call	printf
34*4db555a5SRichard Lowe	movl	$0, %eax
35*4db555a5SRichard Lowe	leave
36*4db555a5SRichard Lowe	ret
37*4db555a5SRichard Lowe.LFE0:
38*4db555a5SRichard Lowe	.size	main, .-main
39*4db555a5SRichard Lowe.globl foo
40*4db555a5SRichard Lowe	.section	.rodata.str1.1
41*4db555a5SRichard Lowe.LC1:
42*4db555a5SRichard Lowe	.string	"foo"
43*4db555a5SRichard Lowe
44*4db555a5SRichard Lowe	.section	.tdata,"awT",@progbits
45*4db555a5SRichard Lowe	.align 8
46*4db555a5SRichard Lowe	.type	foo, @object
47*4db555a5SRichard Lowe	.size	foo, 8
48*4db555a5SRichard Lowefoo:
49*4db555a5SRichard Lowe	.quad	.LC1
50