	.file	"tsc.c"
	.text
.globl check_tsc_unstable
	.type	check_tsc_unstable, @function
check_tsc_unstable:
	movl	tsc_unstable(%rip), %eax
	ret
	.size	check_tsc_unstable, .-check_tsc_unstable
.globl recalibrate_cpu_khz
	.type	recalibrate_cpu_khz, @function
recalibrate_cpu_khz:
	movl	$-19, %eax
	ret
	.size	recalibrate_cpu_khz, .-recalibrate_cpu_khz
	.type	read_tsc, @function
read_tsc:
#APP
# 125 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdtsc
# 0 "" 2
#NO_APP
	salq	$32, %rdx
	mov	%eax, %eax
	orq	%rax, %rdx
	movq	clocksource_tsc+128(%rip), %rax
	cmpq	%rax, %rdx
	cmovae	%rdx, %rax
	ret
	.size	read_tsc, .-read_tsc
	.section	.vsyscall_fn,"ax",@progbits
	.type	vread_tsc, @function
vread_tsc:
#APP
# 456 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/system.h" 1
	661:
	.byte 0x0f,0x1f,0x00

662:
.section .altinstructions,"a"
 .balign 8 
 .quad 661b
 .quad 663f
	 .byte (3*32+17)
	 .byte 662b-661b
	 .byte 664f-663f
	 .byte 0xff + (664f-663f) - (662b-661b)
.previous
.section .altinstr_replacement, "ax"
663:
	mfence
664:
.previous
# 0 "" 2
# 457 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/system.h" 1
	661:
	.byte 0x0f,0x1f,0x00

662:
.section .altinstructions,"a"
 .balign 8 
 .quad 661b
 .quad 663f
	 .byte (3*32+18)
	 .byte 662b-661b
	 .byte 664f-663f
	 .byte 0xff + (664f-663f) - (662b-661b)
.previous
.section .altinstr_replacement, "ax"
663:
	lfence
664:
.previous
# 0 "" 2
# 125 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdtsc
# 0 "" 2
# 456 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/system.h" 1
	661:
	.byte 0x0f,0x1f,0x00

662:
.section .altinstructions,"a"
 .balign 8 
 .quad 661b
 .quad 663f
	 .byte (3*32+17)
	 .byte 662b-661b
	 .byte 664f-663f
	 .byte 0xff + (664f-663f) - (662b-661b)
.previous
.section .altinstr_replacement, "ax"
663:
	mfence
664:
.previous
# 0 "" 2
# 457 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/system.h" 1
	661:
	.byte 0x0f,0x1f,0x00

662:
.section .altinstructions,"a"
 .balign 8 
 .quad 661b
 .quad 663f
	 .byte (3*32+18)
	 .byte 662b-661b
	 .byte 664f-663f
	 .byte 0xff + (664f-663f) - (662b-661b)
.previous
.section .altinstr_replacement, "ax"
663:
	lfence
664:
.previous
# 0 "" 2
#NO_APP
	salq	$32, %rdx
	mov	%eax, %eax
	orq	%rax, %rdx
	movq	__vsyscall_gtod_data+40(%rip), %rax
	cmpq	%rax, %rdx
	cmovae	%rdx, %rax
	ret
	.size	vread_tsc, .-vread_tsc
	.text
	.type	resume_tsc, @function
resume_tsc:
	movq	$0, clocksource_tsc+128(%rip)
	ret
	.size	resume_tsc, .-resume_tsc
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"reliable"
	.section	.init.text,"ax",@progbits
	.type	tsc_setup, @function
tsc_setup:
	subq	$8, %rsp
	movq	$.LC0, %rsi
	call	strcmp
	testl	%eax, %eax
	jne	.L7
	movl	$1, tsc_clocksource_reliable(%rip)
.L7:
	movl	$1, %eax
	addq	$8, %rsp
	ret
	.size	tsc_setup, .-tsc_setup
	.type	cpufreq_tsc, @function
cpufreq_tsc:
	subq	$8, %rsp
	testb	$16, boot_cpu_data+20(%rip)
	je	.L9
	testb	$1, boot_cpu_data+33(%rip)
	jne	.L9
	xorl	%esi, %esi
	movq	$time_cpufreq_notifier_block, %rdi
	call	cpufreq_register_notifier
.L9:
	xorl	%eax, %eax
	addq	$8, %rsp
	ret
	.size	cpufreq_tsc, .-cpufreq_tsc
	.text
	.type	set_cyc2ns_scale, @function
set_cyc2ns_scale:
	pushq	%r12
	movl	%esi, %r12d
	pushq	%rbp
	movq	%rdi, %rbp
	pushq	%rbx
#APP
# 20 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/irqflags.h" 1
	# __raw_save_flags
	pushf ; pop %rbx
# 0 "" 2
# 39 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/irqflags.h" 1
	cli
# 0 "" 2
#NO_APP
	call	sched_clock_idle_sleep_event
	movslq	%r12d, %rsi
	movq	$cyc2ns, %rdi
	movq	__per_cpu_offset(,%rsi,8), %r8
	movq	$cyc2ns_offset, %rcx
#APP
# 125 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdtsc
# 0 "" 2
# 50 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/timer.h" 1
	movl %gs:cpu_number,%esi
# 0 "" 2
#NO_APP
	testq	%rbp, %rbp
	movslq	%esi, %rsi
	movq	__per_cpu_offset(,%rsi,8), %rsi
	movq	(%rsi,%rcx), %r9
	movq	(%rsi,%rdi), %r10
	je	.L11
	movq	%rdx, %rsi
	mov	%eax, %eax
	salq	$32, %rsi
	xorl	%edx, %edx
	orq	%rax, %rsi
	movl	$1024000000, %eax
	imulq	%rsi, %r10
	divq	%rbp
	shrq	$10, %r10
	movq	%rax, (%rdi,%r8)
	imulq	%rax, %rsi
	shrq	$10, %rsi
	subq	%rsi, %r10
	addq	%r9, %r10
	movq	%r10, (%rcx,%r8)
.L11:
	xorl	%edi, %edi
	call	sched_clock_idle_wakeup_event
#APP
# 31 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/irqflags.h" 1
	push %rbx ; popf
# 0 "" 2
#NO_APP
	popq	%rbx
	popq	%rbp
	popq	%r12
	ret
	.size	set_cyc2ns_scale, .-set_cyc2ns_scale
	.section	.rodata.str1.1
.LC1:
	.string	"<5>%s detected: marking TSC unstable.\n"
	.section	.init.text
	.type	dmi_mark_tsc_unstable, @function
dmi_mark_tsc_unstable:
	subq	$8, %rsp
	xorl	%eax, %eax
	movq	8(%rdi), %rsi
	movq	$.LC1, %rdi
	call	printk
	movl	$1, tsc_unstable(%rip)
	xorl	%eax, %eax
	addq	$8, %rsp
	ret
	.size	dmi_mark_tsc_unstable, .-dmi_mark_tsc_unstable
	.section	.rodata.str1.1
.LC2:
	.string	"<4>notsc: Kernel compiled with CONFIG_X86_TSC, cannot disable TSC completely.\n"
	.section	.init.text
.globl notsc_setup
	.type	notsc_setup, @function
notsc_setup:
	subq	$8, %rsp
	movq	$.LC2, %rdi
	xorl	%eax, %eax
	call	printk
	movl	$1, tsc_disabled(%rip)
	movl	$1, %eax
	addq	$8, %rsp
	ret
	.size	notsc_setup, .-notsc_setup
	.section	.rodata.str1.1
.LC3:
	.string	"<6>Marking TSC unstable due to %s\n"
	.text
.globl mark_tsc_unstable
	.type	mark_tsc_unstable, @function
mark_tsc_unstable:
	subq	$8, %rsp
	movq	%rdi, %rsi
	cmpl	$0, tsc_unstable(%rip)
	jne	.L16
	xorl	%eax, %eax
	movl	$1, tsc_unstable(%rip)
	movl	$0, sched_clock_stable(%rip)
	movq	$.LC3, %rdi
	call	printk
	cmpl	$0, clocksource_tsc+64(%rip)
	je	.L18
	movq	$clocksource_tsc, %rdi
	addq	$8, %rsp
	jmp	clocksource_mark_unstable
.L18:
	orq	$64, clocksource_tsc+80(%rip)
	movl	$0, clocksource_tsc+24(%rip)
.L16:
	addq	$8, %rsp
	ret
	.size	mark_tsc_unstable, .-mark_tsc_unstable
	.section	.rodata.str1.1
.LC4:
	.string	"cpufreq changes"
	.text
	.type	time_cpufreq_notifier, @function
time_cpufreq_notifier:
	pushq	%rbx
	movq	$cpu_info, %rax
	movq	%rdx, %rbx
	mov	(%rdx), %edx
	movq	__per_cpu_offset(,%rdx,8), %rdx
	testb	$1, 33(%rdx,%rax)
	jne	.L20
	movq	$boot_cpu_data+152, %rdi
	testb	$2, 12(%rbx)
	jne	.L21
	leaq	152(%rdx,%rax), %rdi
.L21:
	cmpl	$0, ref_freq(%rip)
	jne	.L22
	movl	4(%rbx), %eax
	movl	%eax, ref_freq(%rip)
	movq	(%rdi), %rax
	movq	%rax, loops_per_jiffy_ref(%rip)
	mov	tsc_khz(%rip), %eax
	movq	%rax, tsc_khz_ref(%rip)
.L22:
	testq	%rsi, %rsi
	jne	.L23
	movl	8(%rbx), %eax
	cmpl	%eax, 4(%rbx)
	jb	.L24
	jmp	.L25
.L23:
	cmpq	$1, %rsi
	jne	.L26
	movl	8(%rbx), %eax
	cmpl	%eax, 4(%rbx)
	ja	.L24
	jmp	.L25
.L26:
	cmpq	$8, %rsi
	jne	.L25
.L24:
	mov	ref_freq(%rip), %ecx
	mov	8(%rbx), %eax
	xorl	%edx, %edx
	imulq	loops_per_jiffy_ref(%rip), %rax
	divq	%rcx
	xorl	%edx, %edx
	movq	%rax, (%rdi)
	mov	8(%rbx), %eax
	imulq	tsc_khz_ref(%rip), %rax
	divq	%rcx
	testb	$2, 12(%rbx)
	movl	%eax, tsc_khz(%rip)
	jne	.L25
	movq	$.LC4, %rdi
	call	mark_tsc_unstable
.L25:
	mov	tsc_khz(%rip), %edi
	movl	(%rbx), %esi
	call	set_cyc2ns_scale
.L20:
	xorl	%eax, %eax
	popq	%rbx
	ret
	.size	time_cpufreq_notifier, .-time_cpufreq_notifier
	.type	tsc_read_refs, @function
tsc_read_refs:
	pushq	%r13
	movl	%esi, %r13d
	pushq	%r12
	pushq	%rbp
	movl	$5, %ebp
	pushq	%rbx
	movq	%rdi, %rbx
	subq	$8, %rsp
.L33:
#APP
# 125 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdtsc
# 0 "" 2
#NO_APP
	movq	%rdx, %r12
	mov	%eax, %eax
	salq	$32, %r12
	orq	%rax, %r12
	testl	%r13d, %r13d
	je	.L29
	movl	$240, %edi
	call	hpet_readl
	jmp	.L31
.L29:
	xorl	%eax, %eax
	cmpl	$0, pmtmr_ioport(%rip)
	je	.L31
	call	acpi_pm_read_verified
	andl	$16777215, %eax
.L31:
	mov	%eax, %eax
	movq	%rax, (%rbx)
#APP
# 125 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdtsc
# 0 "" 2
#NO_APP
	movl	%eax, %ecx
	movq	%rdx, %rax
	mov	%ecx, %ecx
	salq	$32, %rax
	orq	%rcx, %rax
	movq	%rax, %rdx
	subq	%r12, %rdx
	cmpq	$49999, %rdx
	jbe	.L32
	decl	%ebp
	jne	.L33
	orq	$-1, %rax
.L32:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	popq	%r12
	popq	%r13
	ret
	.size	tsc_read_refs, .-tsc_read_refs
.globl native_sched_clock
	.type	native_sched_clock, @function
native_sched_clock:
	cmpl	$0, tsc_disabled(%rip)
	je	.L37
	imulq	$1000000, jiffies_64(%rip), %rdx
	movabsq	$-4294667296000000, %rax
	addq	%rax, %rdx
	jmp	.L38
.L37:
#APP
# 125 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdtsc
# 0 "" 2
# 50 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/timer.h" 1
	movl %gs:cpu_number,%esi
# 0 "" 2
#NO_APP
	movq	$cyc2ns_offset, %rcx
	movslq	%esi, %rsi
	salq	$32, %rdx
	movq	__per_cpu_offset(,%rsi,8), %rdi
	movq	$cyc2ns, %rsi
	mov	%eax, %eax
	orq	%rax, %rdx
	imulq	(%rdi,%rsi), %rdx
	shrq	$10, %rdx
	addq	(%rdi,%rcx), %rdx
.L38:
	movq	%rdx, %rax
	ret
	.size	native_sched_clock, .-native_sched_clock
	.section	.rodata.str1.1
.LC5:
	.string	"HPET"
.LC6:
	.string	"PMTIMER"
.LC7:
	.string	"Fast TSC calibration failed\n"
.LC8:
	.string	"Fast TSC calibration using PIT\n"
.LC9:
	.string	"<6>TSC: PIT calibration matches %s. %d loops\n"
.LC10:
	.string	"<4>TSC: Unable to calibrate against PIT\n"
.LC11:
	.string	"TSC: No reference (HPET/PMTIMER) available\n"
.LC12:
	.string	"<4>TSC: HPET/PMTIMER calibration failed.\n"
.LC13:
	.string	"<6>TSC: using %s reference calibration\n"
.LC14:
	.string	"<6>TSC: Using PIT calibration value\n"
.LC15:
	.string	"<4>TSC: HPET/PMTIMER calibration failed. Using PIT calibration\n"
.LC16:
	.string	"<4>TSC: PIT calibration deviates from %s: %lu %lu.\n"
	.text
.globl native_calibrate_tsc
	.type	native_calibrate_tsc, @function
native_calibrate_tsc:
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbp
	pushq	%rbx
	subq	$56, %rsp
	call	is_hpet_enabled
	movl	%eax, %r12d
#APP
# 20 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/irqflags.h" 1
	# __raw_save_flags
	pushf ; pop %rbx
# 0 "" 2
# 39 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/irqflags.h" 1
	cli
# 0 "" 2
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	inb $97, %al
# 0 "" 2
#NO_APP
	andl	$-4, %eax
	orl	$1, %eax
#APP
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	outb %al, $97
# 0 "" 2
#NO_APP
	movb	$-80, %al
#APP
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	outb %al, $67
# 0 "" 2
#NO_APP
	movb	$-1, %al
#APP
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	outb %al, $66
# 0 "" 2
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	outb %al, $66
# 0 "" 2
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	inb $66, %al
# 0 "" 2
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	inb $66, %al
# 0 "" 2
#NO_APP
	xorl	%edi, %edi
	xorl	%esi, %esi
.L41:
#APP
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	inb $66, %al
# 0 "" 2
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	inb $66, %al
# 0 "" 2
#NO_APP
	incb	%al
	jne	.L40
#APP
# 125 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdtsc
# 0 "" 2
#NO_APP
	movq	%rdx, %rdi
	mov	%eax, %eax
	salq	$32, %rdi
	incl	%esi
	orq	%rax, %rdi
	cmpl	$50000, %esi
	jne	.L41
.L40:
#APP
# 125 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdtsc
# 0 "" 2
#NO_APP
	movq	%rdx, %rcx
	mov	%eax, %eax
	salq	$32, %rcx
	orq	%rax, %rcx
	subq	%rdi, %rcx
	cmpl	$5, %esi
	jle	.L42
	movl	$1, %esi
.L46:
	movb	%sil, %al
	movb	%sil, %r8b
	notl	%eax
	xorl	%r13d, %r13d
	movb	%al, %r9b
	xorl	%ebp, %ebp
.L44:
#APP
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	inb $66, %al
# 0 "" 2
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	inb $66, %al
# 0 "" 2
#NO_APP
	cmpb	%r9b, %al
	jne	.L43
#APP
# 125 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdtsc
# 0 "" 2
#NO_APP
	movq	%rdx, %r13
	mov	%eax, %eax
	salq	$32, %r13
	incl	%ebp
	orq	%rax, %r13
	cmpl	$50000, %ebp
	jne	.L44
.L43:
#APP
# 125 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdtsc
# 0 "" 2
#NO_APP
	cmpl	$5, %ebp
	jle	.L42
	salq	$32, %rdx
	mov	%eax, %eax
	orq	%rax, %rdx
	subq	%r13, %rdx
	subq	%rdi, %r13
	leaq	(%rdx,%rcx), %rbp
	movq	%r13, %rax
	shrq	$11, %rax
	cmpq	%rax, %rbp
	jb	.L45
	incl	%esi
	cmpl	$117, %esi
	jne	.L46
	jmp	.L42
.L45:
#APP
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	inb $66, %al
# 0 "" 2
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	inb $66, %al
# 0 "" 2
#NO_APP
	movb	$-2, %dil
	subb	%r8b, %dil
	cmpb	%dil, %al
	je	.L47
.L42:
	movq	$.LC7, %rdi
	xorl	%eax, %eax
	xorl	%r13d, %r13d
	call	printk
	jmp	.L48
.L47:
	movq	%rdx, %rax
	imull	$256000, %esi, %esi
	subq	%rcx, %rax
	mov	%esi, %esi
	movl	$2, %ecx
	cqto
	movq	$.LC8, %rdi
	idivq	%rcx
	xorl	%edx, %edx
	leaq	(%rax,%r13), %r13
	imulq	$1193182, %r13, %r13
	movq	%r13, %rax
	divq	%rsi
	movq	%rax, %r13
	xorl	%eax, %eax
	call	printk
.L48:
#APP
# 31 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/irqflags.h" 1
	push %rbx ; popf
# 0 "" 2
#NO_APP
	testq	%r13, %r13
	jne	.L51
	orq	$-1, %rbp
	movl	$1000, 28(%rsp)
	movl	$0, 24(%rsp)
	movl	$10, %r15d
	movl	$11931, %r14d
	movq	%rbp, %rbx
.L67:
#APP
# 20 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/irqflags.h" 1
	# __raw_save_flags
	pushf ; pop 16(%rsp)
# 0 "" 2
# 39 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/irqflags.h" 1
	cli
# 0 "" 2
#NO_APP
	movl	%r12d, %esi
	leaq	40(%rsp), %rdi
	call	tsc_read_refs
	movq	%rax, %r11
#APP
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	inb $97, %al
# 0 "" 2
#NO_APP
	andl	$-4, %eax
	orl	$1, %eax
#APP
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	outb %al, $97
# 0 "" 2
#NO_APP
	movb	$-80, %al
#APP
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	outb %al, $67
# 0 "" 2
#NO_APP
	movb	%r14b, %al
#APP
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	outb %al, $66
# 0 "" 2
#NO_APP
	movl	%r14d, %eax
	shrl	$8, %eax
#APP
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	outb %al, $66
# 0 "" 2
# 125 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdtsc
# 0 "" 2
#NO_APP
	xorl	%r9d, %r9d
	movq	%rdx, %rcx
	mov	%eax, %eax
	salq	$32, %rcx
	xorl	%esi, %esi
	orq	%rax, %rcx
	orq	$-1, %rdi
	movq	%rcx, %r8
	jmp	.L52
.L55:
#APP
# 125 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdtsc
# 0 "" 2
#NO_APP
	salq	$32, %rdx
	mov	%eax, %eax
	orq	%rax, %rdx
	movq	%rdx, %rax
	subq	%r8, %rax
	mov	%eax, %r8d
	cmpq	%rdi, %rax
	cmovb	%r8, %rdi
	cmpq	%rsi, %rax
	cmova	%r8, %rsi
	incl	%r9d
	movq	%rdx, %r8
.L52:
#APP
# 327 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/io.h" 1
	inb $97, %al
# 0 "" 2
#NO_APP
	testb	$32, %al
	je	.L55
	orq	$-1, %r10
	cmpl	28(%rsp), %r9d
	jl	.L56
	imulq	$10, %rdi, %rdi
	cmpq	%rdi, %rsi
	ja	.L56
	subq	%rcx, %r8
	xorl	%edx, %edx
	mov	%r15d, %ecx
	movq	%r8, %rax
	divq	%rcx
	movq	%rax, %r10
.L56:
	movq	%r10, (%rsp)
	movq	%r11, 8(%rsp)
	movl	%r12d, %esi
	leaq	32(%rsp), %rdi
	call	tsc_read_refs
	movq	(%rsp), %r10
	movq	8(%rsp), %r11
#APP
# 31 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/irqflags.h" 1
	push 16(%rsp) ; popf
# 0 "" 2
#NO_APP
	cmpq	%r10, %rbx
	cmova	%r10, %rbx
	testl	%r12d, %r12d
	jne	.L59
	cmpq	$0, 40(%rsp)
	jne	.L59
	cmpq	$0, 32(%rsp)
	je	.L60
.L59:
	cmpq	$-1, %rax
	je	.L60
	cmpq	$-1, %r11
	je	.L60
	subq	%r11, %rax
	movq	32(%rsp), %rsi
	imulq	$1000000, %rax, %rax
	movq	40(%rsp), %rcx
	movq	%rax, 16(%rsp)
	testl	%r12d, %r12d
	je	.L61
	cmpq	%rcx, %rsi
	movq	%rcx, (%rsp)
	movabsq	$4294967296, %rax
	movl	$4, %edi
	leaq	(%rsi,%rax), %rax
	cmovb	%rax, %rsi
	movq	%rsi, 8(%rsp)
	call	hpet_readl
	movq	(%rsp), %rcx
	mov	%eax, %eax
	movq	8(%rsp), %rsi
	subq	%rcx, %rsi
	movl	$1000000, %ecx
	imulq	%rsi, %rax
	jmp	.L86
.L61:
	orq	$-1, %rax
	movq	%rcx, %rdx
	orq	%rsi, %rdx
	je	.L63
	cmpq	%rcx, %rsi
	leaq	16777216(%rsi), %rax
	cmovb	%rax, %rsi
	subq	%rcx, %rsi
	movl	$3579545, %ecx
	imulq	$1000000000, %rsi, %rax
.L86:
	xorl	%edx, %edx
	divq	%rcx
	xorl	%edx, %edx
	mov	%eax, %ecx
	movq	16(%rsp), %rax
	divq	%rcx
.L63:
	cmpq	%rax, %rbp
	cmova	%rax, %rbp
	imulq	$100, %rbx, %rax
	xorl	%edx, %edx
	mov	%ebp, %ecx
	divq	%rcx
	subq	$90, %rax
	cmpq	$20, %rax
	ja	.L65
	movl	24(%rsp), %edx
	movq	$.LC6, %rax
	incl	%edx
	movq	$.LC5, %rsi
	testl	%r12d, %r12d
	movq	$.LC9, %rdi
	cmove	%rax, %rsi
	xorl	%eax, %eax
	call	printk
	jmp	.L87
.L65:
	cmpq	$-1, %rbx
	jne	.L60
	cmpl	$1, 24(%rsp)
	movl	$5000, %ecx
	sete	%al
	cmovne	28(%rsp), %ecx
	movl	$50, %edx
	testb	%al, %al
	movl	%ecx, 28(%rsp)
	cmovne	%rdx, %r15
	movl	$59659, %ecx
	cmovne	%rcx, %r14
.L60:
	incl	24(%rsp)
	cmpl	$3, 24(%rsp)
	jne	.L67
	cmpq	$-1, %rbx
	jne	.L68
	xorl	%eax, %eax
	movq	$.LC10, %rdi
	call	printk
	testl	%r12d, %r12d
	jne	.L69
	cmpq	$0, 40(%rsp)
	jne	.L69
	movq	$.LC11, %rdi
	cmpq	$0, 32(%rsp)
	je	.L89
.L69:
	cmpq	$-1, %rbp
	jne	.L70
	movq	$.LC12, %rdi
.L89:
	xorl	%eax, %eax
	call	printk
	jmp	.L51
.L70:
	testl	%r12d, %r12d
	movq	$.LC6, %rax
	movq	$.LC5, %rsi
	movq	$.LC13, %rdi
	cmove	%rax, %rsi
	xorl	%eax, %eax
	call	printk
.L87:
	movq	%rbp, %r13
	jmp	.L51
.L68:
	testl	%r12d, %r12d
	jne	.L72
	cmpq	$0, 40(%rsp)
	jne	.L72
	cmpq	$0, 32(%rsp)
	je	.L90
.L72:
	movq	$.LC15, %rdi
	cmpq	$-1, %rbp
	je	.L88
	testl	%r12d, %r12d
	movq	$.LC6, %rax
	movq	$.LC5, %rsi
	movq	%rbp, %rcx
	cmove	%rax, %rsi
	movq	%rbx, %rdx
	movq	$.LC16, %rdi
	xorl	%eax, %eax
	call	printk
.L90:
	movq	$.LC14, %rdi
.L88:
	xorl	%eax, %eax
	movq	%rbx, %r13
	call	printk
.L51:
	addq	$56, %rsp
	movq	%r13, %rax
	popq	%rbx
	popq	%rbp
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	ret
	.size	native_calibrate_tsc, .-native_calibrate_tsc
	.section	.cpuinit.text,"ax",@progbits
.globl unsynchronized_tsc
	.type	unsynchronized_tsc, @function
unsynchronized_tsc:
	pushq	%rbx
	testb	$16, boot_cpu_data+20(%rip)
	movl	$1, %ebx
	je	.L92
	cmpl	$0, tsc_unstable(%rip)
	jne	.L92
	call	apic_is_clustered_box
	testl	%eax, %eax
	jne	.L92
	xorb	%bl, %bl
	testb	$1, boot_cpu_data+33(%rip)
	jne	.L92
	cmpb	$0, boot_cpu_data+1(%rip)
	je	.L93
	movq	cpu_possible_mask(%rip), %rax
	movq	(%rax), %rdi
	andl	$15, %edi
	call	hweight64
	cmpl	$1, %eax
	jbe	.L93
	movl	$1, tsc_unstable(%rip)
.L93:
	movl	tsc_unstable(%rip), %ebx
.L92:
	movl	%ebx, %eax
	popq	%rbx
	ret
	.size	unsynchronized_tsc, .-unsynchronized_tsc
	.section	.rodata.str1.1
.LC17:
	.string	"could not calculate TSC khz"
.LC18:
	.string	"<4>Warning: AMD perfctrs busy ... cpu_khz value may be incorrect.\n"
.LC19:
	.string	"arch/x86/kernel/tsc.c"
.LC20:
	.string	"Detected %lu.%03lu MHz processor.\n"
.LC21:
	.string	"TSCs unsynchronized"
	.section	.init.text
.globl tsc_init
	.type	tsc_init, @function
tsc_init:
	pushq	%r13
	pushq	%r12
	pushq	%rbp
	pushq	%rbx
	subq	$8, %rsp
	call	*x86_init+152(%rip)
	testb	$16, boot_cpu_data+20(%rip)
	je	.L98
	call	*x86_platform(%rip)
	movl	%eax, tsc_khz(%rip)
	movl	%eax, cpu_khz(%rip)
	testl	%eax, %eax
	jne	.L100
	addq	$8, %rsp
	movq	$.LC17, %rdi
	popq	%rbx
	popq	%rbp
	popq	%r12
	popq	%r13
	jmp	mark_tsc_unstable
.L100:
	testb	$1, boot_cpu_data+33(%rip)
	je	.L101
	cmpb	$2, boot_cpu_data+1(%rip)
	jne	.L101
	xorl	%ebp, %ebp
.L103:
	movl	%ebp, %edi
	call	avail_to_resrv_perfctr_nmi_bit
	testl	%eax, %eax
	jne	.L102
	incl	%ebp
	cmpl	$4, %ebp
	jne	.L103
.L102:
	xorl	%ebx, %ebx
	cmpl	$4, %ebp
	sete	%bl
	jne	.L104
	movq	$.LC18, %rdx
	movl	$879, %esi
	movq	$.LC19, %rdi
	xorl	%eax, %eax
	call	warn_slowpath_fmt
	movl	$-1073676285, %ecx
#APP
# 72 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdmsr
# 0 "" 2
#NO_APP
	movq	%rdx, %rsi
	mov	%eax, %eax
	salq	$32, %rsi
	orq	%rax, %rsi
	xorl	%eax, %eax
	movl	%eax, %edx
#APP
# 95 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	wrmsr
# 0 "" 2
#NO_APP
	movl	$-1073676281, %ecx
#APP
# 72 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdmsr
# 0 "" 2
#NO_APP
	movq	%rdx, %r8
	mov	%eax, %eax
	salq	$32, %r8
	movb	$3, %bpl
	orq	%rax, %r8
	jmp	.L105
.L104:
	leal	-1073676284(%rbp), %edi
	call	reserve_perfctr_nmi
	leal	-1073676288(%rbp), %edi
	call	reserve_evntsel_nmi
	xorl	%r8d, %r8d
	xorl	%esi, %esi
.L105:
#APP
# 20 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/irqflags.h" 1
	# __raw_save_flags
	pushf ; pop %r9
# 0 "" 2
# 39 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/irqflags.h" 1
	cli
# 0 "" 2
#NO_APP
	xorl	%edx, %edx
	leal	-1073676284(%rbp), %edi
	movl	%edx, %eax
	movl	%edi, %ecx
#APP
# 95 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	wrmsr
# 0 "" 2
#NO_APP
	movl	$4391030, %eax
	subl	$1073676288, %ebp
	movl	%ebp, %ecx
#APP
# 95 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	wrmsr
# 0 "" 2
# 125 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdtsc
# 0 "" 2
#NO_APP
	movl	%eax, %r10d
.L106:
	movl	%edi, %ecx
#APP
# 72 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdmsr
# 0 "" 2
#NO_APP
	movq	%rdx, %r12
	mov	%eax, %eax
	salq	$32, %r12
	orq	%rax, %r12
#APP
# 125 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	rdtsc
# 0 "" 2
#NO_APP
	movl	%eax, %r13d
	subl	%r10d, %r13d
	cmpl	$99999999, %r13d
	jle	.L106
#APP
# 31 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/irqflags.h" 1
	push %r9 ; popf
# 0 "" 2
#NO_APP
	testl	%ebx, %ebx
	je	.L109
	movl	$-1073676285, %ebx
	xorl	%eax, %eax
	movl	%ebx, %ecx
	movl	%eax, %edx
#APP
# 95 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	wrmsr
# 0 "" 2
#NO_APP
	movl	$-1073676281, %ecx
	movq	%r8, %rdx
	movl	%r8d, %eax
	shrq	$32, %rdx
#APP
# 95 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	wrmsr
# 0 "" 2
#NO_APP
	movq	%rsi, %rdx
	movl	%ebx, %ecx
	shrq	$32, %rdx
	movl	%esi, %eax
#APP
# 95 "/home/hongxun/tmp/comp/linux-2.6.34/arch/x86/include/asm/msr.h" 1
	wrmsr
# 0 "" 2
#NO_APP
	jmp	.L110
.L109:
	call	release_perfctr_nmi
	movl	%ebp, %edi
	call	release_evntsel_nmi
.L110:
	mov	tsc_khz(%rip), %eax
	movslq	%r13d, %r13
	imulq	%r12, %rax
	xorl	%edx, %edx
	divq	%r13
	movl	%eax, cpu_khz(%rip)
.L101:
	movl	cpu_khz(%rip), %eax
	movl	$1000, %ecx
	xorl	%edx, %edx
	movq	$.LC20, %rdi
	divl	%ecx
	orl	$-1, %ebp
	mov	%eax, %esi
	mov	%edx, %edx
	xorl	%eax, %eax
	call	printk
	movq	cpu_possible_mask(%rip), %rbx
	jmp	.L111
.L112:
	mov	cpu_khz(%rip), %edi
	movl	%eax, %esi
	call	set_cyc2ns_scale
.L111:
	incl	%ebp
	movl	$4, %esi
	movslq	%ebp, %rdx
	movq	%rbx, %rdi
	call	find_next_bit
	movl	%eax, %ebp
	cmpl	nr_cpu_ids(%rip), %eax
	jl	.L112
	cmpl	$0, tsc_disabled(%rip)
	jg	.L98
	movl	$1000, %ecx
	mov	tsc_khz(%rip), %eax
	xorl	%edx, %edx
	imulq	$1000, %rax, %rax
	movl	$0, tsc_disabled(%rip)
	divq	%rcx
	movq	%rax, lpj_fine(%rip)
	call	use_tsc_delay
	movq	$bad_tsc_dmi_table, %rdi
	call	dmi_check_system
	call	unsynchronized_tsc
	testl	%eax, %eax
	je	.L113
	movq	$.LC21, %rdi
	call	mark_tsc_unstable
.L113:
	testb	$-128, boot_cpu_data+34(%rip)
	je	.L114
	movl	$1, tsc_clocksource_reliable(%rip)
.L114:
	mov	tsc_khz(%rip), %ebx
	movl	$1000000, %eax
	movl	clocksource_tsc+68(%rip), %ecx
	movl	%ebx, %edx
	salq	%cl, %rax
	shrl	%edx
	mov	%edx, %edx
	leaq	(%rdx,%rax), %rax
	xorl	%edx, %edx
	divq	%rbx
	cmpl	$0, tsc_clocksource_reliable(%rip)
	movl	%eax, clocksource_tsc+64(%rip)
	je	.L115
	andq	$-3, clocksource_tsc+80(%rip)
.L115:
	cmpl	$0, tsc_unstable(%rip)
	je	.L116
	movl	$0, clocksource_tsc+24(%rip)
	andq	$-2, clocksource_tsc+80(%rip)
.L116:
	addq	$8, %rsp
	movq	$clocksource_tsc, %rdi
	popq	%rbx
	popq	%rbp
	popq	%r12
	popq	%r13
	jmp	clocksource_register
.L98:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	popq	%r12
	popq	%r13
	ret
	.size	tsc_init, .-tsc_init
.globl cpu_khz
	.section	.data.read_mostly,"aw",@progbits
	.align 4
	.type	cpu_khz, @object
	.size	cpu_khz, 4
cpu_khz:
	.zero	4
.globl tsc_khz
	.align 4
	.type	tsc_khz, @object
	.size	tsc_khz, 4
tsc_khz:
	.zero	4
.globl cyc2ns
	.section	.data.percpu,"aw",@progbits
	.align 8
	.type	cyc2ns, @object
	.size	cyc2ns, 8
cyc2ns:
	.zero	8
.globl cyc2ns_offset
	.align 8
	.type	cyc2ns_offset, @object
	.size	cyc2ns_offset, 8
cyc2ns_offset:
	.zero	8
	.section	__ksymtab_gpl,"a",@progbits
	.align 16
	.type	__ksymtab_mark_tsc_unstable, @object
	.size	__ksymtab_mark_tsc_unstable, 16
__ksymtab_mark_tsc_unstable:
	.quad	mark_tsc_unstable
	.quad	__kstrtab_mark_tsc_unstable
	.section	.initcall1.init,"aw",@progbits
	.align 8
	.type	__initcall_cpufreq_tsc1, @object
	.size	__initcall_cpufreq_tsc1, 8
__initcall_cpufreq_tsc1:
	.quad	cpufreq_tsc
	.section	__ksymtab,"a",@progbits
	.align 16
	.type	__ksymtab_recalibrate_cpu_khz, @object
	.size	__ksymtab_recalibrate_cpu_khz, 16
__ksymtab_recalibrate_cpu_khz:
	.quad	recalibrate_cpu_khz
	.quad	__kstrtab_recalibrate_cpu_khz
	.section	.init.setup,"aw",@progbits
	.align 8
	.type	__setup_tsc_setup, @object
	.size	__setup_tsc_setup, 24
__setup_tsc_setup:
	.quad	__setup_str_tsc_setup
	.quad	tsc_setup
	.long	0
	.zero	4
	.align 8
	.type	__setup_notsc_setup, @object
	.size	__setup_notsc_setup, 24
__setup_notsc_setup:
	.quad	__setup_str_notsc_setup
	.quad	notsc_setup
	.long	0
	.zero	4
	.section	__ksymtab_gpl
	.align 16
	.type	__ksymtab_check_tsc_unstable, @object
	.size	__ksymtab_check_tsc_unstable, 16
__ksymtab_check_tsc_unstable:
	.quad	check_tsc_unstable
	.quad	__kstrtab_check_tsc_unstable
	.section	__ksymtab
	.align 16
	.type	__ksymtab_tsc_khz, @object
	.size	__ksymtab_tsc_khz, 16
__ksymtab_tsc_khz:
	.quad	tsc_khz
	.quad	__kstrtab_tsc_khz
	.align 16
	.type	__ksymtab_cpu_khz, @object
	.size	__ksymtab_cpu_khz, 16
__ksymtab_cpu_khz:
	.quad	cpu_khz
	.quad	__kstrtab_cpu_khz
	.local	tsc_clocksource_reliable
	.comm	tsc_clocksource_reliable,4,4
	.data
	.align 16
	.type	time_cpufreq_notifier_block, @object
	.size	time_cpufreq_notifier_block, 24
time_cpufreq_notifier_block:
	.quad	time_cpufreq_notifier
	.zero	16
	.local	ref_freq
	.comm	ref_freq,4,4
	.local	loops_per_jiffy_ref
	.comm	loops_per_jiffy_ref,8,8
	.local	tsc_khz_ref
	.comm	tsc_khz_ref,8,8
	.section	.data.read_mostly
	.align 4
	.type	tsc_disabled, @object
	.size	tsc_disabled, 4
tsc_disabled:
	.long	-1
	.section	.rodata.str1.1
.LC22:
	.string	"IBM Thinkpad 380XD"
	.section	.init.data,"aw",@progbits
	.align 16
	.type	bad_tsc_dmi_table, @object
	.size	bad_tsc_dmi_table, 688
bad_tsc_dmi_table:
	.quad	dmi_mark_tsc_unstable
	.quad	.LC22
	.byte	9
	.string	"IBM"
	.zero	75
	.byte	10
	.string	"2635FA0"
	.zero	71
	.zero	160
	.zero	8
	.zero	344
	.section	.data.read_mostly
	.align 4
	.type	tsc_unstable, @object
	.size	tsc_unstable, 4
tsc_unstable:
	.zero	4
	.section	.rodata.str1.1
.LC23:
	.string	"tsc"
	.data
	.align 64
	.type	clocksource_tsc, @object
	.size	clocksource_tsc, 192
clocksource_tsc:
	.quad	.LC23
	.zero	16
	.long	300
	.zero	4
	.quad	read_tsc
	.zero	16
	.quad	-1
	.zero	4
	.long	22
	.zero	8
	.quad	3
	.quad	vread_tsc
	.zero	8
	.quad	resume_tsc
	.zero	80
	.section	__ksymtab_strings,"a",@progbits
	.type	__kstrtab_mark_tsc_unstable, @object
	.size	__kstrtab_mark_tsc_unstable, 18
__kstrtab_mark_tsc_unstable:
	.string	"mark_tsc_unstable"
	.type	__kstrtab_recalibrate_cpu_khz, @object
	.size	__kstrtab_recalibrate_cpu_khz, 20
__kstrtab_recalibrate_cpu_khz:
	.string	"recalibrate_cpu_khz"
	.section	.init.rodata,"a",@progbits
	.type	__setup_str_tsc_setup, @object
	.size	__setup_str_tsc_setup, 5
__setup_str_tsc_setup:
	.string	"tsc="
	.type	__setup_str_notsc_setup, @object
	.size	__setup_str_notsc_setup, 6
__setup_str_notsc_setup:
	.string	"notsc"
	.section	__ksymtab_strings
	.type	__kstrtab_check_tsc_unstable, @object
	.size	__kstrtab_check_tsc_unstable, 19
__kstrtab_check_tsc_unstable:
	.string	"check_tsc_unstable"
	.type	__kstrtab_tsc_khz, @object
	.size	__kstrtab_tsc_khz, 8
__kstrtab_tsc_khz:
	.string	"tsc_khz"
	.type	__kstrtab_cpu_khz, @object
	.size	__kstrtab_cpu_khz, 8
__kstrtab_cpu_khz:
	.string	"cpu_khz"
.globl sched_clock
	.set	sched_clock,native_sched_clock
	.ident	"GCC: (GNU) 4.5.1 20100522 (prerelease)"
	.section	.note.GNU-stack,"",@progbits
