#include "gMat.cuh"
#include "real.h"
#include <assert.h>
#include <iostream>



void basicMultTest(int w){
	std::vector<real> adat={1,2,3,4};
	std::vector<real> bdat={2,0,0,2,0,2};
	std::vector<real> cdat={0,0,0,0,0,0};
	gMat A{adat,2,2};//A= [1 2; 3 4]
	gMat B{bdat,2,3};//B= [2 0 0; 2 0 2]
	gMat C{cdat,2,3};
	
	int mem=2*w*w*sizeof(real);
	
	
	prod(A,B,C,mem);
	std::cout << C << std::endl;
	assert( C.entry(0,0) == 6 );
	assert(C.entry(0,1) == 0 );
	assert(C.entry(0,2) == 4 );
	assert(C.entry(1,0) == 14 );
	assert(C.entry(1,1) == 0 );
	assert(C.entry(1,2) == 8 );
	A.cleanup();
	B.cleanup();
	C.cleanup();

}

void basicMultTestv2(int w, int s){
	std::vector<real> adat={1,2,3,4};
	std::vector<real> bdat={2,0,0,2,0,2};
	std::vector<real> cdat={0,0,0,0,0,0};
	gMat A{adat,2,2};//A= [1 2; 3 4]
	gMat B{bdat,2,3};//B= [2 0 0; 2 0 2]
	gMat C{cdat,2,3};
	
	
	
	prodv2(A, B, C, w, s);
	std::cout << C << std::endl;
	assert( C.entry(0,0) == 6 );
	assert(C.entry(0,1) == 0 );
	assert(C.entry(0,2) == 4 );
	assert(C.entry(1,0) == 14 );
	assert(C.entry(1,1) == 0 );
	assert(C.entry(1,2) == 8 );
	A.cleanup();
	B.cleanup();
	C.cleanup();

}

int main(){
	basicMultTest(1);
/*	basicMultTest(1);
	basicMultTest(2);
	basicMultTestv2(16,1);
	basicMultTestv2(1,2);
	basicMultTestv2(1,3);
	basicMultTestv2(2,1);
	basicMultTestv2(2,2);
*/	
	
	
	std::cout << "SUCCESS!" << std::endl;
}

	.file	"tmpxft_003959c2_00000000-6_test.cudafe1.cpp"
	.text
#APP
	.globl _ZSt21ios_base_library_initv

#NO_APP
	.type	_ZL26__cudaUnregisterBinaryUtilv, @function
_ZL26__cudaUnregisterBinaryUtilv:
.LFB4593:
	.cfi_startproc
	endbr64
	movq	_ZL20__cudaFatCubinHandle(%rip), %rdi
	jmp	__cudaUnregisterFatBinary@PLT
	.cfi_endproc
.LFE4593:
	.size	_ZL26__cudaUnregisterBinaryUtilv, .-_ZL26__cudaUnregisterBinaryUtilv
	.section	.text.startup,"ax",@progbits
	.type	_ZL24__sti____cudaRegisterAllv, @function
_ZL24__sti____cudaRegisterAllv:
.LFB4616:
	.cfi_startproc
	endbr64
	pushq	%rax
	.cfi_def_cfa_offset 16
	leaq	_ZL15__fatDeviceText(%rip), %rdi
	call	__cudaRegisterFatBinary@PLT
	movq	%rax, %rdi
	movq	%rax, _ZL20__cudaFatCubinHandle(%rip)
	call	__cudaRegisterFatBinaryEnd@PLT
	leaq	_ZL26__cudaUnregisterBinaryUtilv(%rip), %rdi
	popq	%rdx
	.cfi_def_cfa_offset 8
	jmp	atexit@PLT
	.cfi_endproc
.LFE4616:
	.size	_ZL24__sti____cudaRegisterAllv, .-_ZL24__sti____cudaRegisterAllv
	.section	.init_array,"aw"
	.align 8
	.quad	_ZL24__sti____cudaRegisterAllv
	.section	.text._ZNSt6vectorIfSaIfEEC2ERKS1_,"axG",@progbits,_ZNSt6vectorIfSaIfEEC5ERKS1_,comdat
	.align 2
	.weak	_ZNSt6vectorIfSaIfEEC2ERKS1_
	.type	_ZNSt6vectorIfSaIfEEC2ERKS1_, @function
_ZNSt6vectorIfSaIfEEC2ERKS1_:
.LFB4936:
	.cfi_startproc
	endbr64
	pushq	%r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	movq	%rsi, %r12
	pushq	%rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	pushq	%rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	movq	8(%rsi), %rbp
	movq	%rdi, %rbx
	subq	(%rsi), %rbp
	movq	$0, (%rdi)
	movq	$0, 8(%rdi)
	movq	$0, 16(%rdi)
	je	.L9
	movabsq	$9223372036854775804, %rax
	cmpq	%rbp, %rax
	jnb	.L6
	call	_ZSt28__throw_bad_array_new_lengthv@PLT
.L6:
	movq	%rbp, %rdi
	call	_Znwm@PLT
	movq	%rax, %rcx
	jmp	.L5
.L9:
	xorl	%ecx, %ecx
.L5:
	addq	%rcx, %rbp
	movq	%rcx, (%rbx)
	movq	%rcx, 8(%rbx)
	movq	%rbp, 16(%rbx)
	movq	(%r12), %rsi
	movq	8(%r12), %rbp
	subq	%rsi, %rbp
	cmpq	$4, %rbp
	jle	.L7
	movq	%rcx, %rdi
	movq	%rbp, %rdx
	call	memmove@PLT
	movq	%rax, %rcx
	jmp	.L8
.L7:
	jne	.L8
	movss	(%rsi), %xmm0
	movss	%xmm0, (%rcx)
.L8:
	addq	%rbp, %rcx
	movq	%rcx, 8(%rbx)
	popq	%rbx
	.cfi_def_cfa_offset 24
	popq	%rbp
	.cfi_def_cfa_offset 16
	popq	%r12
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE4936:
	.size	_ZNSt6vectorIfSaIfEEC2ERKS1_, .-_ZNSt6vectorIfSaIfEEC2ERKS1_
	.weak	_ZNSt6vectorIfSaIfEEC1ERKS1_
	.set	_ZNSt6vectorIfSaIfEEC1ERKS1_,_ZNSt6vectorIfSaIfEEC2ERKS1_
	.section	.text._ZNSt12_Vector_baseIfSaIfEED2Ev,"axG",@progbits,_ZNSt12_Vector_baseIfSaIfEED5Ev,comdat
	.align 2
	.weak	_ZNSt12_Vector_baseIfSaIfEED2Ev
	.type	_ZNSt12_Vector_baseIfSaIfEED2Ev, @function
_ZNSt12_Vector_baseIfSaIfEED2Ev:
.LFB5103:
	.cfi_startproc
	endbr64
	movq	(%rdi), %rax
	testq	%rax, %rax
	je	.L12
	movq	16(%rdi), %rsi
	movq	%rax, %rdi
	subq	%rax, %rsi
	jmp	_ZdlPvm@PLT
.L12:
	ret
	.cfi_endproc
.LFE5103:
	.size	_ZNSt12_Vector_baseIfSaIfEED2Ev, .-_ZNSt12_Vector_baseIfSaIfEED2Ev
	.weak	_ZNSt12_Vector_baseIfSaIfEED1Ev
	.set	_ZNSt12_Vector_baseIfSaIfEED1Ev,_ZNSt12_Vector_baseIfSaIfEED2Ev
	.section	.text._ZNSt6vectorIfSaIfEED2Ev,"axG",@progbits,_ZNSt6vectorIfSaIfEED5Ev,comdat
	.align 2
	.weak	_ZNSt6vectorIfSaIfEED2Ev
	.type	_ZNSt6vectorIfSaIfEED2Ev, @function
_ZNSt6vectorIfSaIfEED2Ev:
.LFB4933:
	.cfi_startproc
	endbr64
	jmp	_ZNSt12_Vector_baseIfSaIfEED2Ev
	.cfi_endproc
.LFE4933:
	.size	_ZNSt6vectorIfSaIfEED2Ev, .-_ZNSt6vectorIfSaIfEED2Ev
	.weak	_ZNSt6vectorIfSaIfEED1Ev
	.set	_ZNSt6vectorIfSaIfEED1Ev,_ZNSt6vectorIfSaIfEED2Ev
	.section	.rodata._ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_.str1.1,"aMS",@progbits,1
.LC0:
	.string	"cannot create std::vector larger than max_size()"
	.section	.text._ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_,"axG",@progbits,_ZNSt6vectorIfSaIfEEC5ESt16initializer_listIfERKS0_,comdat
	.align 2
	.weak	_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_
	.type	_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_, @function
_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_:
.LFB4930:
	.cfi_startproc
	.cfi_personality 0x9b,DW.ref.__gxx_personality_v0
	.cfi_lsda 0x1b,.LLSDA4930
	endbr64
	xorl	%eax, %eax
	pushq	%r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	pushq	%rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	movq	%rdi, %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	leaq	0(,%rdx,4), %rbx
	movq	%rax, (%rdi)
	movq	%rax, 8(%rdi)
	movq	%rax, 16(%rdi)
	movabsq	$9223372036854775804, %rax
	cmpq	%rbx, %rax
	jnb	.L16
	leaq	.LC0(%rip), %rdi
.LEHB0:
	call	_ZSt20__throw_length_errorPKc@PLT
.L16:
	movq	%rsi, %r12
	testq	%rbx, %rbx
	je	.L21
	movq	%rbx, %rdi
	call	_Znwm@PLT
.LEHE0:
	jmp	.L17
.L21:
	xorl	%eax, %eax
.L17:
	leaq	(%rax,%rbx), %rdx
	movq	%rax, 0(%rbp)
	movq	%rdx, 16(%rbp)
	cmpq	$4, %rbx
	jle	.L18
	movq	%rax, %rdi
	movq	%r12, %rsi
	movq	%rbx, %rcx
	rep movsb
	jmp	.L19
.L18:
	jne	.L19
	movss	(%r12), %xmm0
	movss	%xmm0, (%rax)
.L19:
	movq	%rdx, 8(%rbp)
	popq	%rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	popq	%rbp
	.cfi_def_cfa_offset 16
	popq	%r12
	.cfi_def_cfa_offset 8
	ret
.L22:
	.cfi_restore_state
	endbr64
	movq	%rax, %rbx
.L20:
	movq	%rbp, %rdi
	call	_ZNSt12_Vector_baseIfSaIfEED2Ev
	movq	%rbx, %rdi
.LEHB1:
	call	_Unwind_Resume@PLT
.LEHE1:
	.cfi_endproc
.LFE4930:
	.globl	__gxx_personality_v0
	.section	.gcc_except_table._ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_,"aG",@progbits,_ZNSt6vectorIfSaIfEEC5ESt16initializer_listIfERKS0_,comdat
.LLSDA4930:
	.byte	0xff
	.byte	0xff
	.byte	0x1
	.uleb128 .LLSDACSE4930-.LLSDACSB4930
.LLSDACSB4930:
	.uleb128 .LEHB0-.LFB4930
	.uleb128 .LEHE0-.LEHB0
	.uleb128 .L22-.LFB4930
	.uleb128 0
	.uleb128 .LEHB1-.LFB4930
	.uleb128 .LEHE1-.LEHB1
	.uleb128 0
	.uleb128 0
.LLSDACSE4930:
	.section	.text._ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_,"axG",@progbits,_ZNSt6vectorIfSaIfEEC5ESt16initializer_listIfERKS0_,comdat
	.size	_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_, .-_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_
	.weak	_ZNSt6vectorIfSaIfEEC1ESt16initializer_listIfERKS0_
	.set	_ZNSt6vectorIfSaIfEEC1ESt16initializer_listIfERKS0_,_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_
	.text
	.globl	_Z13basicMultTesti
	.type	_Z13basicMultTesti, @function
_Z13basicMultTesti:
.LFB4585:
	.cfi_startproc
	.cfi_personality 0x9b,DW.ref.__gxx_personality_v0
	.cfi_lsda 0x1b,.LLSDA4585
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	movl	$4, %edx
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	movl	%edi, %r12d
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$296, %rsp
	.cfi_def_cfa_offset 352
	movq	%fs:40, %rax
	movq	%rax, 280(%rsp)
	movabsq	$4611686019492741120, %rax
	leaq	232(%rsp), %rbp
	leaq	112(%rsp), %rbx
	movq	%rbx, %rcx
	movq	%rbp, %rsi
	movq	%rax, 232(%rsp)
	movabsq	$4647714816524288000, %rax
	movq	%rax, 240(%rsp)
	leaq	40(%rsp), %rax
	movq	%rax, %rdi
	movq	%rax, (%rsp)
.LEHB2:
	call	_ZNSt6vectorIfSaIfEEC1ESt16initializer_listIfERKS0_
.LEHE2:
	movl	$1, %eax
	movq	%rbx, %rcx
	movq	%rbp, %rsi
	salq	$62, %rax
	movl	$6, %edx
	movq	$1073741824, 232(%rsp)
	movq	%rax, 240(%rsp)
	movq	%rax, 248(%rsp)
	leaq	64(%rsp), %rax
	movq	%rax, %rdi
	movq	%rax, 8(%rsp)
.LEHB3:
	call	_ZNSt6vectorIfSaIfEEC1ESt16initializer_listIfERKS0_
.LEHE3:
	xorl	%eax, %eax
	movl	$6, %ecx
	movq	%rbp, %rdi
	movq	%rbp, %rsi
	rep stosl
	leaq	88(%rsp), %rax
	movq	%rbx, %rcx
	movl	$6, %edx
	movq	%rax, %rdi
	movq	%rax, 16(%rsp)
.LEHB4:
	call	_ZNSt6vectorIfSaIfEEC1ESt16initializer_listIfERKS0_
.LEHE4:
	movq	(%rsp), %rsi
	movq	%rbx, %rdi
.LEHB5:
	call	_ZNSt6vectorIfSaIfEEC1ERKS1_
.LEHE5:
	xorl	%r8d, %r8d
	movl	$2, %ecx
	movl	$2, %edx
	movq	%rbx, %rsi
	leaq	136(%rsp), %r14
	movq	%r14, %rdi
.LEHB6:
	call	_ZN4gMatC1ESt6vectorIfSaIfEEiii@PLT
.LEHE6:
	movq	%rbx, %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	movq	8(%rsp), %rsi
	leaq	152(%rsp), %rax
	movq	%rbx, %rdi
	movq	%rax, 24(%rsp)
.LEHB7:
	call	_ZNSt6vectorIfSaIfEEC1ERKS1_
.LEHE7:
	xorl	%r8d, %r8d
	movl	$3, %ecx
	movl	$2, %edx
	movq	%rbx, %rsi
	leaq	184(%rsp), %r13
	movq	%r13, %rdi
.LEHB8:
	call	_ZN4gMatC1ESt6vectorIfSaIfEEiii@PLT
.LEHE8:
	movq	%rbx, %rdi
	leaq	200(%rsp), %r15
	call	_ZNSt6vectorIfSaIfEED1Ev
	movq	16(%rsp), %rsi
	movq	%rbx, %rdi
.LEHB9:
	call	_ZNSt6vectorIfSaIfEEC1ERKS1_
.LEHE9:
	xorl	%r8d, %r8d
	movl	$3, %ecx
	movl	$2, %edx
	movq	%rbx, %rsi
	movq	%rbp, %rdi
.LEHB10:
	call	_ZN4gMatC1ESt6vectorIfSaIfEEiii@PLT
.LEHE10:
	imull	%r12d, %r12d
	movq	%rbx, %rdi
	leaq	248(%rsp), %rbx
	call	_ZNSt6vectorIfSaIfEED1Ev
	movq	%rbp, %rdx
	movq	%r13, %rsi
	movq	%r14, %rdi
	leal	0(,%r12,8), %ecx
.LEHB11:
	call	_Z4prodRK4gMatS1_RS_i@PLT
	movq	%rbp, %rsi
	leaq	_ZSt4cout(%rip), %rdi
	call	_ZlsRSoR4gMat@PLT
	movq	%rax, %rdi
	call	_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_@PLT
	movq	%r14, %rdi
	call	_ZN4gMat7cleanupEv@PLT
	movq	%r13, %rdi
	call	_ZN4gMat7cleanupEv@PLT
	movq	%rbp, %rdi
	call	_ZN4gMat7cleanupEv@PLT
.LEHE11:
	movq	%rbx, %rdi
	call	_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_disposeEv@PLT
	movq	%r15, %rdi
	call	_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_disposeEv@PLT
	movq	24(%rsp), %rdi
	call	_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_disposeEv@PLT
	movq	16(%rsp), %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	movq	8(%rsp), %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	movq	(%rsp), %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	movq	280(%rsp), %rax
	subq	%fs:40, %rax
	je	.L36
	jmp	.L46
.L39:
	endbr64
	movq	%rax, %rbp
.L26:
	movq	%rbx, %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	jmp	.L27
.L41:
	endbr64
	movq	%rax, %rbp
.L28:
	movq	%rbx, %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	jmp	.L29
.L43:
	endbr64
	movq	%rax, %rbp
.L30:
	movq	%rbx, %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	jmp	.L31
.L45:
	endbr64
	movq	%rax, %rbp
.L32:
	movq	%rbx, %rdi
	call	_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_disposeEv@PLT
	jmp	.L31
.L44:
	endbr64
	movq	%rax, %rbp
.L31:
	movq	%r15, %rdi
	call	_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_disposeEv@PLT
	jmp	.L29
.L42:
	endbr64
	movq	%rax, %rbp
.L29:
	movq	24(%rsp), %rdi
	call	_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_disposeEv@PLT
	jmp	.L27
.L40:
	endbr64
	movq	%rax, %rbp
.L27:
	movq	16(%rsp), %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	jmp	.L33
.L38:
	endbr64
	movq	%rax, %rbp
.L33:
	movq	8(%rsp), %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	jmp	.L34
.L37:
	endbr64
	movq	%rax, %rbp
.L34:
	movq	(%rsp), %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	movq	280(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L46
	movq	%rbp, %rdi
.LEHB12:
	call	_Unwind_Resume@PLT
.LEHE12:
.L46:
	call	__stack_chk_fail@PLT
.L36:
	addq	$296, %rsp
	.cfi_def_cfa_offset 56
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE4585:
	.section	.gcc_except_table,"a",@progbits
.LLSDA4585:
	.byte	0xff
	.byte	0xff
	.byte	0x1
	.uleb128 .LLSDACSE4585-.LLSDACSB4585
.LLSDACSB4585:
	.uleb128 .LEHB2-.LFB4585
	.uleb128 .LEHE2-.LEHB2
	.uleb128 0
	.uleb128 0
	.uleb128 .LEHB3-.LFB4585
	.uleb128 .LEHE3-.LEHB3
	.uleb128 .L37-.LFB4585
	.uleb128 0
	.uleb128 .LEHB4-.LFB4585
	.uleb128 .LEHE4-.LEHB4
	.uleb128 .L38-.LFB4585
	.uleb128 0
	.uleb128 .LEHB5-.LFB4585
	.uleb128 .LEHE5-.LEHB5
	.uleb128 .L40-.LFB4585
	.uleb128 0
	.uleb128 .LEHB6-.LFB4585
	.uleb128 .LEHE6-.LEHB6
	.uleb128 .L39-.LFB4585
	.uleb128 0
	.uleb128 .LEHB7-.LFB4585
	.uleb128 .LEHE7-.LEHB7
	.uleb128 .L42-.LFB4585
	.uleb128 0
	.uleb128 .LEHB8-.LFB4585
	.uleb128 .LEHE8-.LEHB8
	.uleb128 .L41-.LFB4585
	.uleb128 0
	.uleb128 .LEHB9-.LFB4585
	.uleb128 .LEHE9-.LEHB9
	.uleb128 .L44-.LFB4585
	.uleb128 0
	.uleb128 .LEHB10-.LFB4585
	.uleb128 .LEHE10-.LEHB10
	.uleb128 .L43-.LFB4585
	.uleb128 0
	.uleb128 .LEHB11-.LFB4585
	.uleb128 .LEHE11-.LEHB11
	.uleb128 .L45-.LFB4585
	.uleb128 0
	.uleb128 .LEHB12-.LFB4585
	.uleb128 .LEHE12-.LEHB12
	.uleb128 0
	.uleb128 0
.LLSDACSE4585:
	.text
	.size	_Z13basicMultTesti, .-_Z13basicMultTesti
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC1:
	.string	"SUCCESS!"
	.section	.text.startup
	.globl	main
	.type	main, @function
main:
.LFB4590:
	.cfi_startproc
	endbr64
	pushq	%rax
	.cfi_def_cfa_offset 16
	movl	$1, %edi
	call	_Z13basicMultTesti
	leaq	.LC1(%rip), %rsi
	leaq	_ZSt4cout(%rip), %rdi
	call	_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc@PLT
	movq	%rax, %rdi
	call	_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_@PLT
	xorl	%eax, %eax
	popq	%rdx
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE4590:
	.size	main, .-main
	.text
	.globl	_Z15basicMultTestv2ii
	.type	_Z15basicMultTestv2ii, @function
_Z15basicMultTestv2ii:
.LFB4589:
	.cfi_startproc
	.cfi_personality 0x9b,DW.ref.__gxx_personality_v0
	.cfi_lsda 0x1b,.LLSDA4589
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	movl	$4, %edx
	movl	%esi, %r15d
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	movl	%edi, %r14d
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$296, %rsp
	.cfi_def_cfa_offset 352
	movq	%fs:40, %rax
	movq	%rax, 280(%rsp)
	movabsq	$4611686019492741120, %rax
	leaq	232(%rsp), %rbp
	leaq	112(%rsp), %rbx
	movq	%rbx, %rcx
	movq	%rbp, %rsi
	movq	%rax, 232(%rsp)
	movabsq	$4647714816524288000, %rax
	movq	%rax, 240(%rsp)
	leaq	40(%rsp), %rax
	movq	%rax, %rdi
	movq	%rax, (%rsp)
.LEHB13:
	call	_ZNSt6vectorIfSaIfEEC1ESt16initializer_listIfERKS0_
.LEHE13:
	movl	$1, %eax
	movq	%rbx, %rcx
	movq	%rbp, %rsi
	salq	$62, %rax
	movl	$6, %edx
	movq	$1073741824, 232(%rsp)
	movq	%rax, 240(%rsp)
	movq	%rax, 248(%rsp)
	leaq	64(%rsp), %rax
	movq	%rax, %rdi
	movq	%rax, 8(%rsp)
.LEHB14:
	call	_ZNSt6vectorIfSaIfEEC1ESt16initializer_listIfERKS0_
.LEHE14:
	xorl	%eax, %eax
	movl	$6, %ecx
	movq	%rbp, %rdi
	movq	%rbp, %rsi
	rep stosl
	leaq	88(%rsp), %rax
	movq	%rbx, %rcx
	movl	$6, %edx
	movq	%rax, %rdi
	movq	%rax, 16(%rsp)
.LEHB15:
	call	_ZNSt6vectorIfSaIfEEC1ESt16initializer_listIfERKS0_
.LEHE15:
	movq	(%rsp), %rsi
	movq	%rbx, %rdi
.LEHB16:
	call	_ZNSt6vectorIfSaIfEEC1ERKS1_
.LEHE16:
	xorl	%r8d, %r8d
	movl	$2, %ecx
	movl	$2, %edx
	movq	%rbx, %rsi
	leaq	136(%rsp), %r13
	movq	%r13, %rdi
.LEHB17:
	call	_ZN4gMatC1ESt6vectorIfSaIfEEiii@PLT
.LEHE17:
	movq	%rbx, %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	movq	8(%rsp), %rsi
	leaq	152(%rsp), %rax
	movq	%rbx, %rdi
	movq	%rax, 24(%rsp)
.LEHB18:
	call	_ZNSt6vectorIfSaIfEEC1ERKS1_
.LEHE18:
	xorl	%r8d, %r8d
	movl	$3, %ecx
	movl	$2, %edx
	movq	%rbx, %rsi
	leaq	184(%rsp), %r12
	movq	%r12, %rdi
.LEHB19:
	call	_ZN4gMatC1ESt6vectorIfSaIfEEiii@PLT
.LEHE19:
	movq	%rbx, %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	movq	16(%rsp), %rsi
	movq	%rbx, %rdi
.LEHB20:
	call	_ZNSt6vectorIfSaIfEEC1ERKS1_
.LEHE20:
	xorl	%r8d, %r8d
	movl	$3, %ecx
	movl	$2, %edx
	movq	%rbx, %rsi
	movq	%rbp, %rdi
.LEHB21:
	call	_ZN4gMatC1ESt6vectorIfSaIfEEiii@PLT
.LEHE21:
	movq	%rbx, %rdi
	leaq	248(%rsp), %rbx
	call	_ZNSt6vectorIfSaIfEED1Ev
	movl	%r15d, %r8d
	movl	%r14d, %ecx
	movq	%rbp, %rdx
	movq	%r12, %rsi
	movq	%r13, %rdi
.LEHB22:
	call	_Z6prodv2RK4gMatS1_RS_ii@PLT
	movq	%rbp, %rsi
	leaq	_ZSt4cout(%rip), %rdi
	call	_ZlsRSoR4gMat@PLT
	movq	%rax, %rdi
	call	_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_@PLT
	movq	%r13, %rdi
	call	_ZN4gMat7cleanupEv@PLT
	movq	%r12, %rdi
	call	_ZN4gMat7cleanupEv@PLT
	movq	%rbp, %rdi
	call	_ZN4gMat7cleanupEv@PLT
.LEHE22:
	movq	%rbx, %rdi
	call	_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_disposeEv@PLT
	leaq	200(%rsp), %rdi
	call	_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_disposeEv@PLT
	movq	24(%rsp), %rdi
	call	_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_disposeEv@PLT
	movq	16(%rsp), %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	movq	8(%rsp), %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	movq	(%rsp), %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	movq	280(%rsp), %rax
	subq	%fs:40, %rax
	je	.L61
	jmp	.L71
.L64:
	endbr64
	movq	%rax, %rbp
.L51:
	movq	%rbx, %rdi
	movq	%rbp, %rbx
	call	_ZNSt6vectorIfSaIfEED1Ev
	jmp	.L52
.L66:
	endbr64
	movq	%rax, %rbp
.L53:
	movq	%rbx, %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	jmp	.L73
.L68:
	endbr64
	movq	%rax, %rbp
.L55:
	movq	%rbx, %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	jmp	.L56
.L70:
	endbr64
	movq	%rax, %rbp
.L57:
	movq	%rbx, %rdi
	call	_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_disposeEv@PLT
	jmp	.L56
.L69:
	endbr64
	movq	%rax, %rbp
.L56:
	leaq	200(%rsp), %rdi
	call	_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_disposeEv@PLT
.L73:
	movq	%rbp, %rbx
	jmp	.L54
.L67:
	endbr64
	movq	%rax, %rbx
.L54:
	movq	24(%rsp), %rdi
	call	_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_disposeEv@PLT
	jmp	.L52
.L65:
	endbr64
	movq	%rax, %rbx
.L52:
	movq	16(%rsp), %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	jmp	.L58
.L63:
	endbr64
	movq	%rax, %rbx
.L58:
	movq	8(%rsp), %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	jmp	.L59
.L62:
	endbr64
	movq	%rax, %rbx
.L59:
	movq	(%rsp), %rdi
	call	_ZNSt6vectorIfSaIfEED1Ev
	movq	280(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L71
	movq	%rbx, %rdi
.LEHB23:
	call	_Unwind_Resume@PLT
.LEHE23:
.L71:
	call	__stack_chk_fail@PLT
.L61:
	addq	$296, %rsp
	.cfi_def_cfa_offset 56
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE4589:
	.section	.gcc_except_table
.LLSDA4589:
	.byte	0xff
	.byte	0xff
	.byte	0x1
	.uleb128 .LLSDACSE4589-.LLSDACSB4589
.LLSDACSB4589:
	.uleb128 .LEHB13-.LFB4589
	.uleb128 .LEHE13-.LEHB13
	.uleb128 0
	.uleb128 0
	.uleb128 .LEHB14-.LFB4589
	.uleb128 .LEHE14-.LEHB14
	.uleb128 .L62-.LFB4589
	.uleb128 0
	.uleb128 .LEHB15-.LFB4589
	.uleb128 .LEHE15-.LEHB15
	.uleb128 .L63-.LFB4589
	.uleb128 0
	.uleb128 .LEHB16-.LFB4589
	.uleb128 .LEHE16-.LEHB16
	.uleb128 .L65-.LFB4589
	.uleb128 0
	.uleb128 .LEHB17-.LFB4589
	.uleb128 .LEHE17-.LEHB17
	.uleb128 .L64-.LFB4589
	.uleb128 0
	.uleb128 .LEHB18-.LFB4589
	.uleb128 .LEHE18-.LEHB18
	.uleb128 .L67-.LFB4589
	.uleb128 0
	.uleb128 .LEHB19-.LFB4589
	.uleb128 .LEHE19-.LEHB19
	.uleb128 .L66-.LFB4589
	.uleb128 0
	.uleb128 .LEHB20-.LFB4589
	.uleb128 .LEHE20-.LEHB20
	.uleb128 .L69-.LFB4589
	.uleb128 0
	.uleb128 .LEHB21-.LFB4589
	.uleb128 .LEHE21-.LEHB21
	.uleb128 .L68-.LFB4589
	.uleb128 0
	.uleb128 .LEHB22-.LFB4589
	.uleb128 .LEHE22-.LEHB22
	.uleb128 .L70-.LFB4589
	.uleb128 0
	.uleb128 .LEHB23-.LFB4589
	.uleb128 .LEHE23-.LEHB23
	.uleb128 0
	.uleb128 0
.LLSDACSE4589:
	.text
	.size	_Z15basicMultTestv2ii, .-_Z15basicMultTestv2ii
	.section	.nvFatBinSegment,"aw"
	.align 8
	.type	_ZL15__fatDeviceText, @object
	.size	_ZL15__fatDeviceText, 24
_ZL15__fatDeviceText:
	.long	1180844977
	.long	1
	.quad	fatbinData
	.quad	0
	.local	_ZL20__cudaFatCubinHandle
	.comm	_ZL20__cudaFatCubinHandle,8,8
	.hidden	DW.ref.__gxx_personality_v0
	.weak	DW.ref.__gxx_personality_v0
	.section	.data.rel.local.DW.ref.__gxx_personality_v0,"awG",@progbits,DW.ref.__gxx_personality_v0,comdat
	.align 8
	.type	DW.ref.__gxx_personality_v0, @object
	.size	DW.ref.__gxx_personality_v0, 8
DW.ref.__gxx_personality_v0:
	.quad	__gxx_personality_v0
	.ident	"GCC: (Ubuntu 13.3.0-6ubuntu2~24.04) 13.3.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:


#include <hip/hip_runtime.h>
#include "gMat.cuh"
#include "real.h"
#include <assert.h>
#include <iostream>



void basicMultTest(int w){
	std::vector<real> adat={1,2,3,4};
	std::vector<real> bdat={2,0,0,2,0,2};
	std::vector<real> cdat={0,0,0,0,0,0};
	gMat A{adat,2,2};//A= [1 2; 3 4]
	gMat B{bdat,2,3};//B= [2 0 0; 2 0 2]
	gMat C{cdat,2,3};
	
	int mem=2*w*w*sizeof(real);
	
	
	prod(A,B,C,mem);
	std::cout << C << std::endl;
	assert( C.entry(0,0) == 6 );
	assert(C.entry(0,1) == 0 );
	assert(C.entry(0,2) == 4 );
	assert(C.entry(1,0) == 14 );
	assert(C.entry(1,1) == 0 );
	assert(C.entry(1,2) == 8 );
	A.cleanup();
	B.cleanup();
	C.cleanup();

}

void basicMultTestv2(int w, int s){
	std::vector<real> adat={1,2,3,4};
	std::vector<real> bdat={2,0,0,2,0,2};
	std::vector<real> cdat={0,0,0,0,0,0};
	gMat A{adat,2,2};//A= [1 2; 3 4]
	gMat B{bdat,2,3};//B= [2 0 0; 2 0 2]
	gMat C{cdat,2,3};
	
	
	
	prodv2(A, B, C, w, s);
	std::cout << C << std::endl;
	assert( C.entry(0,0) == 6 );
	assert(C.entry(0,1) == 0 );
	assert(C.entry(0,2) == 4 );
	assert(C.entry(1,0) == 14 );
	assert(C.entry(1,1) == 0 );
	assert(C.entry(1,2) == 8 );
	A.cleanup();
	B.cleanup();
	C.cleanup();

}

int main(){
	basicMultTest(1);
/*	basicMultTest(1);
	basicMultTest(2);
	basicMultTestv2(16,1);
	basicMultTestv2(1,2);
	basicMultTestv2(1,3);
	basicMultTestv2(2,1);
	basicMultTestv2(2,2);
*/	
	
	
	std::cout << "SUCCESS!" << std::endl;
}

	.text
	.file	"test.hip"
                                        # Start of file scope inline assembly
	.globl	_ZSt21ios_base_library_initv

                                        # End of file scope inline assembly
	.section	.rodata.cst16,"aM",@progbits,16
	.p2align	4, 0x0                          # -- Begin function _Z13basicMultTesti
.LCPI0_0:
	.long	0x3f800000                      # float 1
	.long	0x40000000                      # float 2
	.long	0x40400000                      # float 3
	.long	0x40800000                      # float 4
	.text
	.globl	_Z13basicMultTesti
	.type	_Z13basicMultTesti,@function
_Z13basicMultTesti:                     # @_Z13basicMultTesti
.Lfunc_begin0:
	.cfi_startproc
	.cfi_personality 3, __gxx_personality_v0
	.cfi_lsda 3, .Lexception0
# %bb.0:
	pushq	%r14
	.cfi_def_cfa_offset 16
	pushq	%rbx
	.cfi_def_cfa_offset 24
	subq	$296, %rsp                      # imm = 0x128
	.cfi_def_cfa_offset 320
	.cfi_offset %rbx, -24
	.cfi_offset %r14, -16
	movl	%edi, %ebx
	movaps	.LCPI0_0(%rip), %xmm0           # xmm0 = [1.0E+0,2.0E+0,3.0E+0,4.0E+0]
	movq	%rsp, %r14
	movups	%xmm0, (%r14)
	leaq	224(%rsp), %rdi
	leaq	104(%rsp), %rcx
	movl	$4, %edx
	movq	%r14, %rsi
	callq	_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_
	movups	.Lconstinit.2(%rip), %xmm0
	movaps	%xmm0, (%r14)
	movabsq	$4611686018427387904, %rax      # imm = 0x4000000000000000
	movq	%rax, 16(%r14)
.Ltmp0:
	leaq	200(%rsp), %rdi
	movq	%rsp, %rsi
	leaq	104(%rsp), %rcx
	movl	$6, %edx
	callq	_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_
.Ltmp1:
# %bb.1:
	xorps	%xmm0, %xmm0
	movq	%rsp, %rsi
	movaps	%xmm0, (%rsi)
	movq	$0, 16(%rsi)
.Ltmp3:
	leaq	176(%rsp), %rdi
	leaq	104(%rsp), %rcx
	movl	$6, %edx
	callq	_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_
.Ltmp4:
# %bb.2:
.Ltmp6:
	leaq	152(%rsp), %rdi
	leaq	224(%rsp), %rsi
	callq	_ZNSt6vectorIfSaIfEEC2ERKS1_
.Ltmp7:
# %bb.3:
.Ltmp9:
	movq	%rsp, %rdi
	leaq	152(%rsp), %rsi
	movl	$2, %edx
	movl	$2, %ecx
	xorl	%r8d, %r8d
	callq	_ZN4gMatC1ESt6vectorIfSaIfEEiii
.Ltmp10:
# %bb.4:
	movq	152(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB0_6
# %bb.5:
	callq	_ZdlPv
.LBB0_6:                                # %_ZNSt6vectorIfSaIfEED2Ev.exit
.Ltmp12:
	leaq	80(%rsp), %rdi
	leaq	200(%rsp), %rsi
	callq	_ZNSt6vectorIfSaIfEEC2ERKS1_
.Ltmp13:
# %bb.7:
.Ltmp15:
	leaq	104(%rsp), %rdi
	leaq	80(%rsp), %rsi
	movl	$2, %edx
	movl	$3, %ecx
	xorl	%r8d, %r8d
	callq	_ZN4gMatC1ESt6vectorIfSaIfEEiii
.Ltmp16:
# %bb.8:
	movq	80(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB0_10
# %bb.9:
	callq	_ZdlPv
.LBB0_10:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit21
.Ltmp18:
	leaq	56(%rsp), %rdi
	leaq	176(%rsp), %rsi
	callq	_ZNSt6vectorIfSaIfEEC2ERKS1_
.Ltmp19:
# %bb.11:
.Ltmp21:
	leaq	248(%rsp), %rdi
	leaq	56(%rsp), %rsi
	movl	$2, %edx
	movl	$3, %ecx
	xorl	%r8d, %r8d
	callq	_ZN4gMatC1ESt6vectorIfSaIfEEiii
.Ltmp22:
# %bb.12:
	movq	56(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB0_14
# %bb.13:
	callq	_ZdlPv
.LBB0_14:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit23
	imull	%ebx, %ebx
	shll	$3, %ebx
.Ltmp24:
	movq	%rsp, %rdi
	leaq	104(%rsp), %rsi
	leaq	248(%rsp), %rdx
	movl	%ebx, %ecx
	callq	_Z4prodRK4gMatS1_RS_i
.Ltmp25:
# %bb.15:
.Ltmp26:
	leaq	248(%rsp), %rsi
	movl	$_ZSt4cout, %edi
	callq	_ZlsRSoR4gMat
.Ltmp27:
# %bb.16:
	movq	%rax, %rbx
	movq	(%rax), %rax
	movq	-24(%rax), %rdi
	addq	%rbx, %rdi
.Ltmp28:
	movl	$10, %esi
	callq	_ZNKSt9basic_iosIcSt11char_traitsIcEE5widenEc
.Ltmp29:
# %bb.17:                               # %.noexc
.Ltmp30:
	movsbl	%al, %esi
	movq	%rbx, %rdi
	callq	_ZNSo3putEc
.Ltmp31:
# %bb.18:                               # %.noexc57
.Ltmp32:
	movq	%rax, %rdi
	callq	_ZNSo5flushEv
.Ltmp33:
# %bb.19:                               # %_ZNSolsEPFRSoS_E.exit
.Ltmp34:
	movq	%rsp, %rdi
	callq	_ZN4gMat7cleanupEv
.Ltmp35:
# %bb.20:
.Ltmp36:
	leaq	104(%rsp), %rdi
	callq	_ZN4gMat7cleanupEv
.Ltmp37:
# %bb.21:
.Ltmp38:
	leaq	248(%rsp), %rdi
	callq	_ZN4gMat7cleanupEv
.Ltmp39:
# %bb.22:
	leaq	280(%rsp), %rax
	movq	-16(%rax), %rdi
	cmpq	%rax, %rdi
	je	.LBB0_24
# %bb.23:                               # %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i.i
	callq	_ZdlPv
.LBB0_24:                               # %_ZN4gMatD2Ev.exit
	leaq	136(%rsp), %rax
	movq	-16(%rax), %rdi
	cmpq	%rax, %rdi
	je	.LBB0_26
# %bb.25:                               # %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i.i24
	callq	_ZdlPv
.LBB0_26:                               # %_ZN4gMatD2Ev.exit26
	leaq	32(%rsp), %rax
	movq	-16(%rax), %rdi
	cmpq	%rax, %rdi
	je	.LBB0_28
# %bb.27:                               # %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i.i27
	callq	_ZdlPv
.LBB0_28:                               # %_ZN4gMatD2Ev.exit29
	movq	176(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB0_30
# %bb.29:
	callq	_ZdlPv
.LBB0_30:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit31
	movq	200(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB0_32
# %bb.31:
	callq	_ZdlPv
.LBB0_32:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit33
	movq	224(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB0_34
# %bb.33:
	callq	_ZdlPv
.LBB0_34:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit35
	addq	$296, %rsp                      # imm = 0x128
	.cfi_def_cfa_offset 24
	popq	%rbx
	.cfi_def_cfa_offset 16
	popq	%r14
	.cfi_def_cfa_offset 8
	retq
.LBB0_42:
	.cfi_def_cfa_offset 320
.Ltmp23:
	movq	%rax, %rbx
	movq	56(%rsp), %rdi
	testq	%rdi, %rdi
	jne	.LBB0_44
	jmp	.LBB0_45
.LBB0_41:
.Ltmp20:
	movq	%rax, %rbx
	jmp	.LBB0_45
.LBB0_40:
.Ltmp17:
	movq	%rax, %rbx
	movq	80(%rsp), %rdi
	testq	%rdi, %rdi
	jne	.LBB0_46
	jmp	.LBB0_47
.LBB0_39:
.Ltmp14:
	movq	%rax, %rbx
	jmp	.LBB0_47
.LBB0_38:
.Ltmp11:
	movq	%rax, %rbx
	movq	152(%rsp), %rdi
	testq	%rdi, %rdi
	jne	.LBB0_48
	jmp	.LBB0_49
.LBB0_37:
.Ltmp8:
	movq	%rax, %rbx
	jmp	.LBB0_49
.LBB0_36:
.Ltmp5:
	movq	%rax, %rbx
	jmp	.LBB0_51
.LBB0_35:
.Ltmp2:
	movq	%rax, %rbx
	jmp	.LBB0_53
.LBB0_43:
.Ltmp40:
	movq	%rax, %rbx
	leaq	280(%rsp), %rax
	movq	-16(%rax), %rdi
	cmpq	%rax, %rdi
	je	.LBB0_45
.LBB0_44:                               # %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i.i42
	callq	_ZdlPv
.LBB0_45:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit41
	leaq	136(%rsp), %rax
	movq	-16(%rax), %rdi
	cmpq	%rax, %rdi
	je	.LBB0_47
.LBB0_46:                               # %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i.i45
	callq	_ZdlPv
.LBB0_47:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit39
	leaq	32(%rsp), %rax
	movq	-16(%rax), %rdi
	cmpq	%rax, %rdi
	je	.LBB0_49
.LBB0_48:                               # %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i.i48
	callq	_ZdlPv
.LBB0_49:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit37
	movq	176(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB0_51
# %bb.50:
	callq	_ZdlPv
.LBB0_51:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit52
	movq	200(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB0_53
# %bb.52:
	callq	_ZdlPv
.LBB0_53:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit54
	movq	224(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB0_55
# %bb.54:
	callq	_ZdlPv
.LBB0_55:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit56
	movq	%rbx, %rdi
	callq	_Unwind_Resume@PLT
.Lfunc_end0:
	.size	_Z13basicMultTesti, .Lfunc_end0-_Z13basicMultTesti
	.cfi_endproc
	.section	.gcc_except_table,"a",@progbits
	.p2align	2, 0x0
GCC_except_table0:
.Lexception0:
	.byte	255                             # @LPStart Encoding = omit
	.byte	255                             # @TType Encoding = omit
	.byte	1                               # Call site Encoding = uleb128
	.uleb128 .Lcst_end0-.Lcst_begin0
.Lcst_begin0:
	.uleb128 .Lfunc_begin0-.Lfunc_begin0    # >> Call Site 1 <<
	.uleb128 .Ltmp0-.Lfunc_begin0           #   Call between .Lfunc_begin0 and .Ltmp0
	.byte	0                               #     has no landing pad
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp0-.Lfunc_begin0           # >> Call Site 2 <<
	.uleb128 .Ltmp1-.Ltmp0                  #   Call between .Ltmp0 and .Ltmp1
	.uleb128 .Ltmp2-.Lfunc_begin0           #     jumps to .Ltmp2
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp3-.Lfunc_begin0           # >> Call Site 3 <<
	.uleb128 .Ltmp4-.Ltmp3                  #   Call between .Ltmp3 and .Ltmp4
	.uleb128 .Ltmp5-.Lfunc_begin0           #     jumps to .Ltmp5
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp6-.Lfunc_begin0           # >> Call Site 4 <<
	.uleb128 .Ltmp7-.Ltmp6                  #   Call between .Ltmp6 and .Ltmp7
	.uleb128 .Ltmp8-.Lfunc_begin0           #     jumps to .Ltmp8
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp9-.Lfunc_begin0           # >> Call Site 5 <<
	.uleb128 .Ltmp10-.Ltmp9                 #   Call between .Ltmp9 and .Ltmp10
	.uleb128 .Ltmp11-.Lfunc_begin0          #     jumps to .Ltmp11
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp12-.Lfunc_begin0          # >> Call Site 6 <<
	.uleb128 .Ltmp13-.Ltmp12                #   Call between .Ltmp12 and .Ltmp13
	.uleb128 .Ltmp14-.Lfunc_begin0          #     jumps to .Ltmp14
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp15-.Lfunc_begin0          # >> Call Site 7 <<
	.uleb128 .Ltmp16-.Ltmp15                #   Call between .Ltmp15 and .Ltmp16
	.uleb128 .Ltmp17-.Lfunc_begin0          #     jumps to .Ltmp17
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp18-.Lfunc_begin0          # >> Call Site 8 <<
	.uleb128 .Ltmp19-.Ltmp18                #   Call between .Ltmp18 and .Ltmp19
	.uleb128 .Ltmp20-.Lfunc_begin0          #     jumps to .Ltmp20
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp21-.Lfunc_begin0          # >> Call Site 9 <<
	.uleb128 .Ltmp22-.Ltmp21                #   Call between .Ltmp21 and .Ltmp22
	.uleb128 .Ltmp23-.Lfunc_begin0          #     jumps to .Ltmp23
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp24-.Lfunc_begin0          # >> Call Site 10 <<
	.uleb128 .Ltmp39-.Ltmp24                #   Call between .Ltmp24 and .Ltmp39
	.uleb128 .Ltmp40-.Lfunc_begin0          #     jumps to .Ltmp40
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp39-.Lfunc_begin0          # >> Call Site 11 <<
	.uleb128 .Lfunc_end0-.Ltmp39            #   Call between .Ltmp39 and .Lfunc_end0
	.byte	0                               #     has no landing pad
	.byte	0                               #   On action: cleanup
.Lcst_end0:
	.p2align	2, 0x0
                                        # -- End function
	.section	.text._ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_,"axG",@progbits,_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_,comdat
	.weak	_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_ # -- Begin function _ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_
	.p2align	1, 0x90
	.type	_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_,@function
_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_: # @_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_
.Lfunc_begin1:
	.cfi_startproc
	.cfi_personality 3, __gxx_personality_v0
	.cfi_lsda 3, .Lexception1
# %bb.0:
	pushq	%r14
	.cfi_def_cfa_offset 16
	pushq	%rbx
	.cfi_def_cfa_offset 24
	pushq	%rax
	.cfi_def_cfa_offset 32
	.cfi_offset %rbx, -24
	.cfi_offset %r14, -16
	movq	%rdi, %rbx
	xorps	%xmm0, %xmm0
	movups	%xmm0, (%rdi)
	movq	$0, 16(%rdi)
	leaq	(%rsi,%rdx,4), %rdx
.Ltmp41:
	callq	_ZNSt6vectorIfSaIfEE19_M_range_initializeIPKfEEvT_S5_St20forward_iterator_tag
.Ltmp42:
# %bb.1:
	addq	$8, %rsp
	.cfi_def_cfa_offset 24
	popq	%rbx
	.cfi_def_cfa_offset 16
	popq	%r14
	.cfi_def_cfa_offset 8
	retq
.LBB1_2:
	.cfi_def_cfa_offset 32
.Ltmp43:
	movq	%rax, %r14
	movq	(%rbx), %rdi
	testq	%rdi, %rdi
	je	.LBB1_4
# %bb.3:
	callq	_ZdlPv
.LBB1_4:                                # %_ZNSt12_Vector_baseIfSaIfEED2Ev.exit
	movq	%r14, %rdi
	callq	_Unwind_Resume@PLT
.Lfunc_end1:
	.size	_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_, .Lfunc_end1-_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_
	.cfi_endproc
	.section	.gcc_except_table._ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_,"aG",@progbits,_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_,comdat
	.p2align	2, 0x0
GCC_except_table1:
.Lexception1:
	.byte	255                             # @LPStart Encoding = omit
	.byte	255                             # @TType Encoding = omit
	.byte	1                               # Call site Encoding = uleb128
	.uleb128 .Lcst_end1-.Lcst_begin1
.Lcst_begin1:
	.uleb128 .Ltmp41-.Lfunc_begin1          # >> Call Site 1 <<
	.uleb128 .Ltmp42-.Ltmp41                #   Call between .Ltmp41 and .Ltmp42
	.uleb128 .Ltmp43-.Lfunc_begin1          #     jumps to .Ltmp43
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp42-.Lfunc_begin1          # >> Call Site 2 <<
	.uleb128 .Lfunc_end1-.Ltmp42            #   Call between .Ltmp42 and .Lfunc_end1
	.byte	0                               #     has no landing pad
	.byte	0                               #   On action: cleanup
.Lcst_end1:
	.p2align	2, 0x0
                                        # -- End function
	.section	.text._ZNSt6vectorIfSaIfEEC2ERKS1_,"axG",@progbits,_ZNSt6vectorIfSaIfEEC2ERKS1_,comdat
	.weak	_ZNSt6vectorIfSaIfEEC2ERKS1_    # -- Begin function _ZNSt6vectorIfSaIfEEC2ERKS1_
	.p2align	1, 0x90
	.type	_ZNSt6vectorIfSaIfEEC2ERKS1_,@function
_ZNSt6vectorIfSaIfEEC2ERKS1_:           # @_ZNSt6vectorIfSaIfEEC2ERKS1_
	.cfi_startproc
# %bb.0:
	pushq	%r15
	.cfi_def_cfa_offset 16
	pushq	%r14
	.cfi_def_cfa_offset 24
	pushq	%r12
	.cfi_def_cfa_offset 32
	pushq	%rbx
	.cfi_def_cfa_offset 40
	pushq	%rax
	.cfi_def_cfa_offset 48
	.cfi_offset %rbx, -40
	.cfi_offset %r12, -32
	.cfi_offset %r14, -24
	.cfi_offset %r15, -16
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	8(%rsi), %rax
	movq	(%rsi), %rcx
	movq	%rax, %r12
	subq	%rcx, %r12
	sarq	$2, %r12
	xorps	%xmm0, %xmm0
	movups	%xmm0, (%rdi)
	movq	$0, 16(%rdi)
	cmpq	%rcx, %rax
	je	.LBB2_1
# %bb.2:
	movq	%rbx, %rdi
	movq	%r12, %rsi
	xorl	%edx, %edx
	callq	_ZNSt15__new_allocatorIfE8allocateEmPKv
	movq	%rax, %r15
	jmp	.LBB2_3
.LBB2_1:
	xorl	%r15d, %r15d
.LBB2_3:
	movq	%r15, (%rbx)
	movq	%r15, 8(%rbx)
	leaq	(%r15,%r12,4), %rax
	movq	%rax, 16(%rbx)
	movq	(%r14), %rsi
	movq	8(%r14), %r14
	subq	%rsi, %r14
	cmpq	$5, %r14
	jl	.LBB2_5
# %bb.4:
	movq	%r15, %rdi
	movq	%r14, %rdx
	callq	memmove@PLT
.LBB2_7:
	addq	%r14, %r15
	movq	%r15, 8(%rbx)
	addq	$8, %rsp
	.cfi_def_cfa_offset 40
	popq	%rbx
	.cfi_def_cfa_offset 32
	popq	%r12
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	retq
.LBB2_5:
	.cfi_def_cfa_offset 48
	cmpq	$4, %r14
	jne	.LBB2_7
# %bb.6:
	movss	(%rsi), %xmm0                   # xmm0 = mem[0],zero,zero,zero
	movss	%xmm0, (%r15)
	jmp	.LBB2_7
.Lfunc_end2:
	.size	_ZNSt6vectorIfSaIfEEC2ERKS1_, .Lfunc_end2-_ZNSt6vectorIfSaIfEEC2ERKS1_
	.cfi_endproc
                                        # -- End function
	.section	.rodata.cst16,"aM",@progbits,16
	.p2align	4, 0x0                          # -- Begin function _Z15basicMultTestv2ii
.LCPI3_0:
	.long	0x3f800000                      # float 1
	.long	0x40000000                      # float 2
	.long	0x40400000                      # float 3
	.long	0x40800000                      # float 4
	.text
	.globl	_Z15basicMultTestv2ii
	.type	_Z15basicMultTestv2ii,@function
_Z15basicMultTestv2ii:                  # @_Z15basicMultTestv2ii
.Lfunc_begin2:
	.cfi_startproc
	.cfi_personality 3, __gxx_personality_v0
	.cfi_lsda 3, .Lexception2
# %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	pushq	%r14
	.cfi_def_cfa_offset 24
	pushq	%rbx
	.cfi_def_cfa_offset 32
	subq	$288, %rsp                      # imm = 0x120
	.cfi_def_cfa_offset 320
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	.cfi_offset %rbp, -16
	movl	%esi, %ebx
	movl	%edi, %ebp
	movaps	.LCPI3_0(%rip), %xmm0           # xmm0 = [1.0E+0,2.0E+0,3.0E+0,4.0E+0]
	movq	%rsp, %r14
	movups	%xmm0, (%r14)
	leaq	216(%rsp), %rdi
	leaq	96(%rsp), %rcx
	movl	$4, %edx
	movq	%r14, %rsi
	callq	_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_
	movups	.Lconstinit.2(%rip), %xmm0
	movaps	%xmm0, (%r14)
	movabsq	$4611686018427387904, %rax      # imm = 0x4000000000000000
	movq	%rax, 16(%r14)
.Ltmp44:
	leaq	192(%rsp), %rdi
	movq	%rsp, %rsi
	leaq	96(%rsp), %rcx
	movl	$6, %edx
	callq	_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_
.Ltmp45:
# %bb.1:
	xorps	%xmm0, %xmm0
	movq	%rsp, %rsi
	movaps	%xmm0, (%rsi)
	movq	$0, 16(%rsi)
.Ltmp47:
	leaq	168(%rsp), %rdi
	leaq	96(%rsp), %rcx
	movl	$6, %edx
	callq	_ZNSt6vectorIfSaIfEEC2ESt16initializer_listIfERKS0_
.Ltmp48:
# %bb.2:
.Ltmp50:
	leaq	144(%rsp), %rdi
	leaq	216(%rsp), %rsi
	callq	_ZNSt6vectorIfSaIfEEC2ERKS1_
.Ltmp51:
# %bb.3:
.Ltmp53:
	movq	%rsp, %rdi
	leaq	144(%rsp), %rsi
	movl	$2, %edx
	movl	$2, %ecx
	xorl	%r8d, %r8d
	callq	_ZN4gMatC1ESt6vectorIfSaIfEEiii
.Ltmp54:
# %bb.4:
	movq	144(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB3_6
# %bb.5:
	callq	_ZdlPv
.LBB3_6:                                # %_ZNSt6vectorIfSaIfEED2Ev.exit
.Ltmp56:
	leaq	72(%rsp), %rdi
	leaq	192(%rsp), %rsi
	callq	_ZNSt6vectorIfSaIfEEC2ERKS1_
.Ltmp57:
# %bb.7:
.Ltmp59:
	leaq	96(%rsp), %rdi
	leaq	72(%rsp), %rsi
	movl	$2, %edx
	movl	$3, %ecx
	xorl	%r8d, %r8d
	callq	_ZN4gMatC1ESt6vectorIfSaIfEEiii
.Ltmp60:
# %bb.8:
	movq	72(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB3_10
# %bb.9:
	callq	_ZdlPv
.LBB3_10:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit20
.Ltmp62:
	leaq	48(%rsp), %rdi
	leaq	168(%rsp), %rsi
	callq	_ZNSt6vectorIfSaIfEEC2ERKS1_
.Ltmp63:
# %bb.11:
.Ltmp65:
	leaq	240(%rsp), %rdi
	leaq	48(%rsp), %rsi
	movl	$2, %edx
	movl	$3, %ecx
	xorl	%r8d, %r8d
	callq	_ZN4gMatC1ESt6vectorIfSaIfEEiii
.Ltmp66:
# %bb.12:
	movq	48(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB3_14
# %bb.13:
	callq	_ZdlPv
.LBB3_14:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit22
.Ltmp68:
	movq	%rsp, %rdi
	leaq	96(%rsp), %rsi
	leaq	240(%rsp), %rdx
	movl	%ebp, %ecx
	movl	%ebx, %r8d
	callq	_Z6prodv2RK4gMatS1_RS_ii
.Ltmp69:
# %bb.15:
.Ltmp70:
	leaq	240(%rsp), %rsi
	movl	$_ZSt4cout, %edi
	callq	_ZlsRSoR4gMat
.Ltmp71:
# %bb.16:
	movq	%rax, %rbx
	movq	(%rax), %rax
	movq	-24(%rax), %rdi
	addq	%rbx, %rdi
.Ltmp72:
	movl	$10, %esi
	callq	_ZNKSt9basic_iosIcSt11char_traitsIcEE5widenEc
.Ltmp73:
# %bb.17:                               # %.noexc
.Ltmp74:
	movsbl	%al, %esi
	movq	%rbx, %rdi
	callq	_ZNSo3putEc
.Ltmp75:
# %bb.18:                               # %.noexc56
.Ltmp76:
	movq	%rax, %rdi
	callq	_ZNSo5flushEv
.Ltmp77:
# %bb.19:                               # %_ZNSolsEPFRSoS_E.exit
.Ltmp78:
	movq	%rsp, %rdi
	callq	_ZN4gMat7cleanupEv
.Ltmp79:
# %bb.20:
.Ltmp80:
	leaq	96(%rsp), %rdi
	callq	_ZN4gMat7cleanupEv
.Ltmp81:
# %bb.21:
.Ltmp82:
	leaq	240(%rsp), %rdi
	callq	_ZN4gMat7cleanupEv
.Ltmp83:
# %bb.22:
	leaq	272(%rsp), %rax
	movq	-16(%rax), %rdi
	cmpq	%rax, %rdi
	je	.LBB3_24
# %bb.23:                               # %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i.i
	callq	_ZdlPv
.LBB3_24:                               # %_ZN4gMatD2Ev.exit
	leaq	128(%rsp), %rax
	movq	-16(%rax), %rdi
	cmpq	%rax, %rdi
	je	.LBB3_26
# %bb.25:                               # %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i.i23
	callq	_ZdlPv
.LBB3_26:                               # %_ZN4gMatD2Ev.exit25
	leaq	32(%rsp), %rax
	movq	-16(%rax), %rdi
	cmpq	%rax, %rdi
	je	.LBB3_28
# %bb.27:                               # %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i.i26
	callq	_ZdlPv
.LBB3_28:                               # %_ZN4gMatD2Ev.exit28
	movq	168(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB3_30
# %bb.29:
	callq	_ZdlPv
.LBB3_30:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit30
	movq	192(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB3_32
# %bb.31:
	callq	_ZdlPv
.LBB3_32:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit32
	movq	216(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB3_34
# %bb.33:
	callq	_ZdlPv
.LBB3_34:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit34
	addq	$288, %rsp                      # imm = 0x120
	.cfi_def_cfa_offset 32
	popq	%rbx
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%rbp
	.cfi_def_cfa_offset 8
	retq
.LBB3_42:
	.cfi_def_cfa_offset 320
.Ltmp67:
	movq	%rax, %rbx
	movq	48(%rsp), %rdi
	testq	%rdi, %rdi
	jne	.LBB3_44
	jmp	.LBB3_45
.LBB3_41:
.Ltmp64:
	movq	%rax, %rbx
	jmp	.LBB3_45
.LBB3_40:
.Ltmp61:
	movq	%rax, %rbx
	movq	72(%rsp), %rdi
	testq	%rdi, %rdi
	jne	.LBB3_46
	jmp	.LBB3_47
.LBB3_39:
.Ltmp58:
	movq	%rax, %rbx
	jmp	.LBB3_47
.LBB3_38:
.Ltmp55:
	movq	%rax, %rbx
	movq	144(%rsp), %rdi
	testq	%rdi, %rdi
	jne	.LBB3_48
	jmp	.LBB3_49
.LBB3_37:
.Ltmp52:
	movq	%rax, %rbx
	jmp	.LBB3_49
.LBB3_36:
.Ltmp49:
	movq	%rax, %rbx
	jmp	.LBB3_51
.LBB3_35:
.Ltmp46:
	movq	%rax, %rbx
	jmp	.LBB3_53
.LBB3_43:
.Ltmp84:
	movq	%rax, %rbx
	leaq	272(%rsp), %rax
	movq	-16(%rax), %rdi
	cmpq	%rax, %rdi
	je	.LBB3_45
.LBB3_44:                               # %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i.i41
	callq	_ZdlPv
.LBB3_45:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit40
	leaq	128(%rsp), %rax
	movq	-16(%rax), %rdi
	cmpq	%rax, %rdi
	je	.LBB3_47
.LBB3_46:                               # %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i.i44
	callq	_ZdlPv
.LBB3_47:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit38
	leaq	32(%rsp), %rax
	movq	-16(%rax), %rdi
	cmpq	%rax, %rdi
	je	.LBB3_49
.LBB3_48:                               # %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i.i47
	callq	_ZdlPv
.LBB3_49:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit36
	movq	168(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB3_51
# %bb.50:
	callq	_ZdlPv
.LBB3_51:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit51
	movq	192(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB3_53
# %bb.52:
	callq	_ZdlPv
.LBB3_53:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit53
	movq	216(%rsp), %rdi
	testq	%rdi, %rdi
	je	.LBB3_55
# %bb.54:
	callq	_ZdlPv
.LBB3_55:                               # %_ZNSt6vectorIfSaIfEED2Ev.exit55
	movq	%rbx, %rdi
	callq	_Unwind_Resume@PLT
.Lfunc_end3:
	.size	_Z15basicMultTestv2ii, .Lfunc_end3-_Z15basicMultTestv2ii
	.cfi_endproc
	.section	.gcc_except_table,"a",@progbits
	.p2align	2, 0x0
GCC_except_table3:
.Lexception2:
	.byte	255                             # @LPStart Encoding = omit
	.byte	255                             # @TType Encoding = omit
	.byte	1                               # Call site Encoding = uleb128
	.uleb128 .Lcst_end2-.Lcst_begin2
.Lcst_begin2:
	.uleb128 .Lfunc_begin2-.Lfunc_begin2    # >> Call Site 1 <<
	.uleb128 .Ltmp44-.Lfunc_begin2          #   Call between .Lfunc_begin2 and .Ltmp44
	.byte	0                               #     has no landing pad
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp44-.Lfunc_begin2          # >> Call Site 2 <<
	.uleb128 .Ltmp45-.Ltmp44                #   Call between .Ltmp44 and .Ltmp45
	.uleb128 .Ltmp46-.Lfunc_begin2          #     jumps to .Ltmp46
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp47-.Lfunc_begin2          # >> Call Site 3 <<
	.uleb128 .Ltmp48-.Ltmp47                #   Call between .Ltmp47 and .Ltmp48
	.uleb128 .Ltmp49-.Lfunc_begin2          #     jumps to .Ltmp49
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp50-.Lfunc_begin2          # >> Call Site 4 <<
	.uleb128 .Ltmp51-.Ltmp50                #   Call between .Ltmp50 and .Ltmp51
	.uleb128 .Ltmp52-.Lfunc_begin2          #     jumps to .Ltmp52
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp53-.Lfunc_begin2          # >> Call Site 5 <<
	.uleb128 .Ltmp54-.Ltmp53                #   Call between .Ltmp53 and .Ltmp54
	.uleb128 .Ltmp55-.Lfunc_begin2          #     jumps to .Ltmp55
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp56-.Lfunc_begin2          # >> Call Site 6 <<
	.uleb128 .Ltmp57-.Ltmp56                #   Call between .Ltmp56 and .Ltmp57
	.uleb128 .Ltmp58-.Lfunc_begin2          #     jumps to .Ltmp58
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp59-.Lfunc_begin2          # >> Call Site 7 <<
	.uleb128 .Ltmp60-.Ltmp59                #   Call between .Ltmp59 and .Ltmp60
	.uleb128 .Ltmp61-.Lfunc_begin2          #     jumps to .Ltmp61
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp62-.Lfunc_begin2          # >> Call Site 8 <<
	.uleb128 .Ltmp63-.Ltmp62                #   Call between .Ltmp62 and .Ltmp63
	.uleb128 .Ltmp64-.Lfunc_begin2          #     jumps to .Ltmp64
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp65-.Lfunc_begin2          # >> Call Site 9 <<
	.uleb128 .Ltmp66-.Ltmp65                #   Call between .Ltmp65 and .Ltmp66
	.uleb128 .Ltmp67-.Lfunc_begin2          #     jumps to .Ltmp67
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp68-.Lfunc_begin2          # >> Call Site 10 <<
	.uleb128 .Ltmp83-.Ltmp68                #   Call between .Ltmp68 and .Ltmp83
	.uleb128 .Ltmp84-.Lfunc_begin2          #     jumps to .Ltmp84
	.byte	0                               #   On action: cleanup
	.uleb128 .Ltmp83-.Lfunc_begin2          # >> Call Site 11 <<
	.uleb128 .Lfunc_end3-.Ltmp83            #   Call between .Ltmp83 and .Lfunc_end3
	.byte	0                               #     has no landing pad
	.byte	0                               #   On action: cleanup
.Lcst_end2:
	.p2align	2, 0x0
                                        # -- End function
	.text
	.globl	main                            # -- Begin function main
	.type	main,@function
main:                                   # @main
	.cfi_startproc
# %bb.0:
	pushq	%rbx
	.cfi_def_cfa_offset 16
	.cfi_offset %rbx, -16
	movl	$1, %edi
	callq	_Z13basicMultTesti
	movl	$_ZSt4cout, %ebx
	movl	$_ZSt4cout, %edi
	movl	$.L.str, %esi
	movl	$8, %edx
	callq	_ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l
	movq	_ZSt4cout(%rip), %rax
	movq	-24(%rax), %rdi
	addq	%rbx, %rdi
	movl	$10, %esi
	callq	_ZNKSt9basic_iosIcSt11char_traitsIcEE5widenEc
	movsbl	%al, %esi
	movl	$_ZSt4cout, %edi
	callq	_ZNSo3putEc
	movq	%rax, %rdi
	callq	_ZNSo5flushEv
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 8
	retq
.Lfunc_end4:
	.size	main, .Lfunc_end4-main
	.cfi_endproc
                                        # -- End function
	.section	.text._ZNSt6vectorIfSaIfEE19_M_range_initializeIPKfEEvT_S5_St20forward_iterator_tag,"axG",@progbits,_ZNSt6vectorIfSaIfEE19_M_range_initializeIPKfEEvT_S5_St20forward_iterator_tag,comdat
	.weak	_ZNSt6vectorIfSaIfEE19_M_range_initializeIPKfEEvT_S5_St20forward_iterator_tag # -- Begin function _ZNSt6vectorIfSaIfEE19_M_range_initializeIPKfEEvT_S5_St20forward_iterator_tag
	.p2align	1, 0x90
	.type	_ZNSt6vectorIfSaIfEE19_M_range_initializeIPKfEEvT_S5_St20forward_iterator_tag,@function
_ZNSt6vectorIfSaIfEE19_M_range_initializeIPKfEEvT_S5_St20forward_iterator_tag: # @_ZNSt6vectorIfSaIfEE19_M_range_initializeIPKfEEvT_S5_St20forward_iterator_tag
	.cfi_startproc
# %bb.0:
	pushq	%r15
	.cfi_def_cfa_offset 16
	pushq	%r14
	.cfi_def_cfa_offset 24
	pushq	%r13
	.cfi_def_cfa_offset 32
	pushq	%r12
	.cfi_def_cfa_offset 40
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r13, -32
	.cfi_offset %r14, -24
	.cfi_offset %r15, -16
	movq	%rdx, %r14
	subq	%rsi, %r14
	movq	%r14, %r13
	sarq	$2, %r13
	movq	%r13, %rax
	shrq	$61, %rax
	jne	.LBB5_9
# %bb.1:                                # %_ZNSt6vectorIfSaIfEE17_S_check_init_lenEmRKS0_.exit
	movq	%rsi, %r15
	movq	%rdi, %rbx
	cmpq	%rsi, %rdx
	je	.LBB5_2
# %bb.3:
	movq	%rbx, %rdi
	movq	%r13, %rsi
	xorl	%edx, %edx
	callq	_ZNSt15__new_allocatorIfE8allocateEmPKv
	movq	%rax, %r12
	jmp	.LBB5_4
.LBB5_2:
	xorl	%r12d, %r12d
.LBB5_4:                                # %_ZNSt12_Vector_baseIfSaIfEE11_M_allocateEm.exit
	movq	%r12, (%rbx)
	leaq	(%r12,%r13,4), %rax
	movq	%rax, 16(%rbx)
	cmpq	$5, %r14
	jl	.LBB5_6
# %bb.5:
	movq	%r12, %rdi
	movq	%r15, %rsi
	movq	%r14, %rdx
	callq	memmove@PLT
.LBB5_8:                                # %_ZSt22__uninitialized_copy_aIPKfPffET0_T_S4_S3_RSaIT1_E.exit
	addq	%r14, %r12
	movq	%r12, 8(%rbx)
	popq	%rbx
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	retq
.LBB5_6:
	.cfi_def_cfa_offset 48
	cmpq	$4, %r14
	jne	.LBB5_8
# %bb.7:
	movss	(%r15), %xmm0                   # xmm0 = mem[0],zero,zero,zero
	movss	%xmm0, (%r12)
	jmp	.LBB5_8
.LBB5_9:
	movl	$.L.str.4, %edi
	callq	_ZSt20__throw_length_errorPKc
.Lfunc_end5:
	.size	_ZNSt6vectorIfSaIfEE19_M_range_initializeIPKfEEvT_S5_St20forward_iterator_tag, .Lfunc_end5-_ZNSt6vectorIfSaIfEE19_M_range_initializeIPKfEEvT_S5_St20forward_iterator_tag
	.cfi_endproc
                                        # -- End function
	.section	.text._ZNSt15__new_allocatorIfE8allocateEmPKv,"axG",@progbits,_ZNSt15__new_allocatorIfE8allocateEmPKv,comdat
	.weak	_ZNSt15__new_allocatorIfE8allocateEmPKv # -- Begin function _ZNSt15__new_allocatorIfE8allocateEmPKv
	.p2align	1, 0x90
	.type	_ZNSt15__new_allocatorIfE8allocateEmPKv,@function
_ZNSt15__new_allocatorIfE8allocateEmPKv: # @_ZNSt15__new_allocatorIfE8allocateEmPKv
	.cfi_startproc
# %bb.0:
	pushq	%rax
	.cfi_def_cfa_offset 16
	movq	%rsi, %rax
	shrq	$61, %rax
	jne	.LBB6_1
# %bb.3:
	shlq	$2, %rsi
	movq	%rsi, %rdi
	popq	%rax
	.cfi_def_cfa_offset 8
	jmp	_Znwm                           # TAILCALL
.LBB6_1:
	.cfi_def_cfa_offset 16
	shrq	$62, %rsi
	je	.LBB6_2
# %bb.4:
	callq	_ZSt28__throw_bad_array_new_lengthv
.LBB6_2:
	callq	_ZSt17__throw_bad_allocv
.Lfunc_end6:
	.size	_ZNSt15__new_allocatorIfE8allocateEmPKv, .Lfunc_end6-_ZNSt15__new_allocatorIfE8allocateEmPKv
	.cfi_endproc
                                        # -- End function
	.type	.Lconstinit.2,@object           # @constinit.2
	.section	.rodata,"a",@progbits
	.p2align	2, 0x0
.Lconstinit.2:
	.long	0x40000000                      # float 2
	.long	0x00000000                      # float 0
	.long	0x00000000                      # float 0
	.long	0x40000000                      # float 2
	.long	0x00000000                      # float 0
	.long	0x40000000                      # float 2
	.size	.Lconstinit.2, 24

	.type	.L.str,@object                  # @.str
	.section	.rodata.str1.1,"aMS",@progbits,1
.L.str:
	.asciz	"SUCCESS!"
	.size	.L.str, 9

	.type	.L.str.4,@object                # @.str.4
.L.str.4:
	.asciz	"cannot create std::vector larger than max_size()"
	.size	.L.str.4, 49

	.type	__hip_cuid_,@object             # @__hip_cuid_
	.bss
	.globl	__hip_cuid_
__hip_cuid_:
	.byte	0                               # 0x0
	.size	__hip_cuid_, 1

	.ident	"AMD clang version 18.0.0git (https://github.com/RadeonOpenCompute/llvm-project roc-6.3.2 25012 e5bf7e55c91490b07c49d8960fa7983d864936c4)"
	.section	".note.GNU-stack","",@progbits
	.addrsig
	.addrsig_sym __gxx_personality_v0
	.addrsig_sym _Unwind_Resume
	.addrsig_sym _ZSt4cout
	.addrsig_sym __hip_cuid_

	.text
	.p2alignl 7, 3214868480
	.fill 96, 4, 3214868480
	.type	__hip_cuid_,@object             ; @__hip_cuid_
	.section	.bss,"aw",@nobits
	.globl	__hip_cuid_
__hip_cuid_:
	.byte	0                               ; 0x0
	.size	__hip_cuid_, 1

	.ident	"AMD clang version 18.0.0git (https://github.com/RadeonOpenCompute/llvm-project roc-6.3.2 25012 e5bf7e55c91490b07c49d8960fa7983d864936c4)"
	.section	".note.GNU-stack","",@progbits
	.addrsig
	.addrsig_sym __hip_cuid_
	.amdgcn_target "amdgcn-amd-amdhsa--gfx1100"
	.amdgpu_metadata
---
amdhsa.kernels:  []
amdhsa.target:   amdgcn-amd-amdhsa--gfx1100
amdhsa.version:
  - 1
  - 2
...

	.end_amdgpu_metadata
