	.file	"stretchby2.c"
gcc2_compiled.:
.text
	.p2align 2
.globl stretchby2
	.type	 stretchby2,@function
stretchby2:

        pushl   %edi                    // Put EDI on Stack
        pushl   %esi                    // Put ESI on Stack
		pushl	%ebx

        movl    16(%esp),%esi           // Source Address
        movl    24(%esp),%edx           // Source Height
        movl    32(%esp),%edi           // Destination Address

        movl    20(%esp),%ebx           // Source Width to EBX
        addl    %ebx,%ebx               // Double Source Width -> Dest. Width
        addl    36(%esp),%ebx           // Add Destination Skip

// Double line in horizontal and vertical direction

.L2:  
        movl    20(%esp),%ecx           // Source Width
.L1:
        movb    (%esi),%al              // Get Pixel to AL
        movb    %al,%ah                 // Double Pixel to AX
        incl    %esi                    // Next Position in Source
        movw    %ax,(%edi)              // Put 2 Pixels to Destination
  	    movw    %ax,(%edi,%ebx)         // Double Line
        addl    $2,%edi                 // Next Destination Position
        decl    %ecx                    // Decrease Counter
        jnz     .L1                     // Repeat
                
        addl    %ebx,%edi               // Add Destination-Skip + 2 * Width
        addl    36(%esp),%edi           // Add Destination-Skip

        addl    28(%esp),%esi           // Add Source-Skip

        decl    %edx                    // Subtract Height Counter
        jnz     .L2                     // Repeat

		popl	%ebx
        popl    %esi                    // Get old ESI from Stack
        popl    %edi
        ret


.Lfe1:
	.size	 stretchby2,.Lfe1-stretchby2
	.ident	"GCC: (GNU) 2.9-beos-991026"
