No subject
bogus at does.not.exist.com
bogus at does.not.exist.com
Fri Mar 27 11:03:12 CET 2009
mlp_dotproduct_sse2_2 seem to be slower than any kind of C code.
Suggestions for improvement (if possible) are welcome.
Ramiro Polla
P.S.: Don't mind the comments beside the sse code. They've probably
grown to be very wrong.
P.P.S.: To remind what the code does: multiply a vector of up to 8
4-byte aligned 24-bit values (state) by 16-byte aligned 16-bit values
(coeffs).
--0015175cb2ec5b6d230468070524
Content-Type: text/x-csrc; charset=US-ASCII; name="mlpdsp_sse2.c"
Content-Disposition: attachment; filename="mlpdsp_sse2.c"
Content-Transfer-Encoding: base64
X-Attachment-Id: f_ftry4lnb1
REVDTEFSRV9BU01fQ09OU1QoMTYsICB4bW1fcmVnLCB4bW1tYXNrKSA9IHsweDAwMDAwZmZmMDAw
MDBmZmZVTEwsIDB4MDAwMDBmZmYwMDAwMGZmZlVMTH07CkRFQ0xBUkVfQVNNX0NPTlNUKCA4LCB1
aW50NjRfdCwgc3NlbWFzaykgPSAgMHgwMDAwMGZmZjAwMDAwZmZmVUxMOwoKc3RhdGljIGludDY0
X3QgbWxwX2RvdHByb2R1Y3Rfc3NlMl8yKGludDMyX3QgKnN0YXRlLCBpbnQzMl90ICpjb2VmZnMp
CnsKICAgIGludDY0X3QgYWNjdW0gPSAwOwoKICAgIF9fYXNtX18gdm9sYXRpbGUoCiAgICAgICAg
Im1vdnEgIk1BTkdMRShzc2VtYXNrKSIsICUlbW02XG5cdCIgLyogbW02ID0gMDAwMDBmZmYwMDAw
MGZmZiAqLwogICAgICAgICJtb3ZxICAgICAgICAgICAgICAoJTIpLCAlJW1tMVxuXHQiIC8qIG1t
MSA9IGNjY2NjY2MxY2NjY2NjYzIgKi8KICAgICAgICAicHNodWZ3ICAgICQweDg4LCAlJW1tMSwg
JSVtbTdcblx0IiAvKiBtbTcgPSBjY2MxY2NjMmNjYzFjY2MyICovCiAgICAgICAgIm1vdnEgICAg
ICAgICAgICAgICglMSksICUlbW0wXG5cdCIgLyogbW0wID0geHhzc3NzczF4eHNzc3NzMiAqLwog
ICAgICAgICJtb3ZxICAgICAgICAgICAgICUlbW0wLCAlJW1tMVxuXHQiIC8qIG1tMSA9IHh4c3Nz
c3MxeHhzc3NzczIgKi8KICAgICAgICAicHNyYWQgICAgICQweDBjLCAgICAgICAgJSVtbTBcblx0
IiAvKiBtbTAgPSB4eHh4eHNzMXh4eHh4c3MyICovCiAgICAgICAgInBhbmQgICAgICAgICAgICAg
JSVtbTYsICUlbW0xXG5cdCIgLyogbW0xID0gMDAwMDBzczEwMDAwMHNzMiAqLwogICAgICAgICJw
YWNrc3NkdyAgICAgICAgICUlbW0xLCAlJW1tMFxuXHQiIC8qIG1tMCA9IHhzczF4c3MyMHNzMTBz
czIgKi8KICAgICAgICAicG1hZGR3ZCAgICAgICAgICAlJW1tNywgJSVtbTBcblx0IiAvKiBtbTAg
PSB4aGltdWwxMnhsb211bDEyICovCiAgICAgICAgIm1vdnEgICAgICAgICAgICAgJSVtbTAsICUl
bW0zXG5cdCIgLyogbW0zID0geGhpbXVsMTJ4bG9tdWwxMiAqLwogICAgICAgICJtb3ZxICAgICAg
ICAgICAgICUlbW0wLCAlJW1tNFxuXHQiIC8qIG1tNCA9IHhoaW11bDEyeGxvbXVsMTIgKi8KICAg
ICAgICAicHNyYWQgICAgICQweDFmLCAgICAgICAgJSVtbTBcblx0IiAvKiBtbTAgPSB4eHh4aGkx
Mnh4eHhsbzEyICovCiAgICAgICAgInB1bnBja2xkcSAgICAgICAgJSVtbTAsICUlbW0zXG5cdCIg
LyogbW0zID0geHh4eHh4eHh4aGltdWwxMiAqLwogICAgICAgICJwdW5wY2toZHEgICAgICAgICUl
bW0wLCAlJW1tNFxuXHQiIC8qIG1tNCA9IHh4eHh4eHh4eGxvbXVsMTIgKi8KICAgICAgICAicHNs
bHEgICAgICQweDBjLCAgICAgICAgJSVtbTNcblx0IiAvKiBtbTMgPSB4eHh4eHhoaW11bDEyMDAw
ICovCiAgICAgICAgInBhZGRxICAgICAgICAgICAgJSVtbTQsICUlbW0zXG5cdCIgLyogbW0zID0g
eHh4eHh4c3VtbXVsX18xMiAqLwogICAgICAgICJtb3ZxICAgICAgICAgICAgICUlbW0zLCAgICAl
MFxuXHQiIC8qIGFjY3VtID0gbW0zICovCiAgICAgICAgImVtbXMgICAgICAgICAgICAgICAgICAg
ICAgICAgXG5cdCIKICAgICAgICA6ICI9bSIoYWNjdW0pIDogInIiKHN0YXRlKSwgInIiKGNvZWZm
cykKICAgICk7CgogICAgcmV0dXJuIGFjY3VtOwp9CgpzdGF0aWMgaW50NjRfdCBtbHBfZG90cHJv
ZHVjdF9zc2UyXzQoaW50MzJfdCAqc3RhdGUsIGludDMyX3QgKmNvZWZmcykKewogICAgaW50NjRf
dCBhY2N1bSA9IDA7CgogICAgX19hc21fXyB2b2xhdGlsZSgKICAgICAgICAibW92ZHFhICJNQU5H
TEUoeG1tbWFzaykiLCAlJXhtbTZcblx0IiAvKiB4bW02ID0gMDAwMDBmZmYwMDAwMGZmZjAwMDAw
ZmZmMDAwMDBmZmYgKi8KICAgICAgICAibW92ZHFhICAgICAgICAgICAgICAoJTIpLCAlJXhtbTdc
blx0IiAvKiB4bW03ID0gY2NjY2NjYzFjY2NjY2NjMmNjY2NjY2MzY2NjY2NjYzQgKi8KICAgICAg
ICAicGFja3NzZHcgICAgICAgICAgJSV4bW03LCAlJXhtbTdcblx0IiAvKiB4bW03ID0gY2NjMWNj
YzJjY2MzY2NjNGNjYzFjY2MyY2NjM2NjYzQgKi8KICAgICAgICAibW92ZHF1ICAgICAgICAgICAg
ICAoJTEpLCAlJXhtbTBcblx0IiAvKiB4bW0wID0geHhzc3NzczF4eHNzc3NzMnh4c3Nzc3MzeHhz
c3NzczQgKi8KICAgICAgICAibW92ZHFhICAgICAgICAgICAgJSV4bW0wLCAlJXhtbTFcblx0IiAv
KiB4bW0xID0geHhzc3NzczF4eHNzc3NzMnh4c3Nzc3MzeHhzc3NzczQgKi8KICAgICAgICAicHNy
YWQgICAgIC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dW5wY2toZHEgICAgICAgICAl
JXhtbTcsICUleG1tMFxuXHQiIC8qIHhtbTAgPSBzeCBjMSpoMStjMipoMixzeCBjMypoMytjNCpo
NCAqLwogICAgICAgICJwc2xscSAgICAgJDB4MGMsICAgICAgICAgICUleG1tM1xuXHQiIC8qIHht
bTMgPSBzeCBjMSpoMStjMipoMiA8PCAxMixzeCBjMypoMytjNCpoNCA8PCAxMiAqLwogICAgICAg
ICJwYWRkcSAgICAgICAgICAgICAlJXhtbTMsICUleG1tMFxuXHQiIC8qIHhtbTAgPSBjMSpzMStj
MipzMixjMypzMytjNCpzNCAqLwogICAgICAgICJtb3ZobHBzICAgICAgICAgICAlJXhtbTAsICUl
eG1tN1xuXHQiCiAgICAgICAgInBhZGRxICAgICAgICAgICAgICUleG1tNywgJSV4bW0wXG5cdCIK
ICAgICAgICAibW92cSAgICAgICAgICAgICAgJSV4bW0wLCAgICAgJTBcblx0IgogICAgICAgIDog
Ij1tIihhY2N1bSkgOiAiciIoc3RhdGUpLCAiciIoY29lZmZzKQogICAgKTsKCiAgICByZXR1cm4g
YWNjdW07Cn0KCnN0YXRpYyBpbnQ2NF90IG1scF9kb3Rwcm9kdWN0X3NzZTJfOChpbnQzMl90ICpz
dGF0ZSwgaW50MzJfdCAqY29lZmZzKQp7CiAgICBpbnQ2NF90IGFjY3VtID0gMDsKCiAgICBfX2Fz
bV9fIHZvbGF0aWxlKAogICAgICAgICJtb3ZkcWEgIk1BTkdMRSh4bW1tYXNrKSIsICUleG1tNlxu
XHQiIC8qIHhtbTYgPSAwMDAwMGZmZjAwMDAwZmZmMDAwMDBmZmYwMDAwMGZmZiAqLwogICAgICAg
ICJtb3ZkcWEgICAgICAgICAgICAgICglMiksICUleG1tN1xuXHQiIC8qIHhtbTcgPSBjY2NjY2Nj
MWNjY2NjY2MyY2NjY2NjYzNjY2NjY2NjNCAqLwogICAgICAgICJtb3ZkcWEgICAgICAgICAgICAx
NiglMiksICUleG1tNVxuXHQiIC8qIHhtbT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ZWZmcykKICAgICk7CgogICAgcmV0dXJuIGFjY3VtOwp9Cg==
--0015175cb2ec5b6d230468070524
Content-Type: text/x-csrc; charset=US-ASCII; name="mlpdsp_sse4.c"
Content-Disposition: attachment; filename="mlpdsp_sse4.c"
Content-Transfer-Encoding: base64
X-Attachment-Id: f_ftry4uld2
c3RhdGljIGludDY0X3QgbWxwX2RvdHByb2R1Y3Rfc3NlNF8yKGludDMyX3QgKnN0YXRlLCBpbnQz
Ml90ICpjb2VmZnMpCnsKICAgIGludDY0X3QgYWNjdW0gPSAwOwoKICAgIF9fYXNtX18gdm9sYXRp
bGUoCiAgICAgICAgIm1vdnEgICAgICAgICAgICAoJTEpLCAlJXhtbTFcblx0IiAvKiB4bW0xID0g
czFzMjAwMDAgKi8KICAgICAgICAicHNodWZkICQweDE0LCAgICglMiksICUleG1tMlxuXHQiIC8q
IHhtbTIgPSBjMWMyYzJjMSAqLwogICAgICAgICJwc2h1ZmQgJDB4MTQsICUleG1tMSwgJSV4bW00
XG5cdCIgLyogeG1tNCA9IHMxczJzMnMxICovCiAgICAgICAgInBtdWxkcSAgICAgICAgJSV4bW00
LCAlJXhtbTJcblx0IiAvKiB4bW0yID0gczEqYzEsczIqYzIgKi8KICAgICAgICAibW92aGxwcyAg
ICAgICAlJXhtbTIsICUleG1tN1xuXHQiIC8qIHhtbTcgPSBzMSpjMSxzMSpjMSAqLwogICAgICAg
ICJwYWRkcSAgICAgICAgICUleG1tNywgJSV4bW0yXG5cdCIgLyogeG1tMiA9IChkb24ndCBjYXJl
KSxzMSpjMStzMipjMiAqLwogICAgICAgICJtb3ZxICAgICAgICAgICUleG1tMiwgICAgICUwXG5c
dCIKICAgICAgICA6ICI9bSIoYWNjdW0pIDogInIiKHN0YXRlKSwgInIiKGNvZWZmcykKICAgICk7
CgogICAgcmV0dXJuIGFjY3VtOwp9CgpzdGF0aWMgaW50NjRfdCBtbHBfZG90cHJvZHVjdF9zc2U0
XzQoaW50MzJfdCAqc3RhdGUsIGludDMyX3QgKmNvZWZmcykKewogICAgaW50NjRfdCBhY2N1bSA9
IDA7CgogICAgX19hc21fXyB2b2xhdGlsZSgKICAgICAgICAibW92ZHFhICAgICAgICAgICglMiks
ICUleG1tMFxuXHQiIC8qIHhtbTAgPSBjMWMyYzNjNCAqLwogICAgICAgICJtb3ZkcXUgICAgICAg
ICAgKCUxKSwgJSV4bW0xXG5cdCIgLyogeG1tMSA9IHMxczJzM3M0ICovCiAgICAgICAgInBzaHVm
ZCAkMHgxNCwgJSV4bW0wLCAlJXhtbTJcblx0IiAvKiB4bW0yID0gYzFjMmMyYzEgKi8KICAgICAg
ICAicHNodWZkICQweGJlLCAlJXhtbTAsICUleG1tM1xuXHQiIC8qIHhtbTMgPSBjM2M0YzRjMyAq
LwogICAgICAgICJwc2h1ZmQgJDB4MTQsICUleG1tMSwgJSV4bW00XG5cdCIgLyogeG1tNCA9IHMx
czJzMnMxICovCiAgICAgICAgInBzaHVmZCAkMHhiZSwgJSV4bW0xLCAlJXhtbTVcblx0IiAvKiB4
bW01ID0gczNzNHM0czMgKi8KICAgICAgICAicG11bGRxICAgICAgICAlJXhtbTQsICUleG1tMlxu
XHQiIC8qIHhtbTIgPSBzMSpjMSxzMipjMiAqLwogICAgICAgICJwbXVsZHEgICAgICAgICUleG1t
NSwgJSV4bW0zXG5cdCIgLyogeG1tMyA9IHMzKmMzLHM0KmM0ICovCiAgICAgICAgInBhZGRxICAg
ICAgICAgJSV4bW0zLCAlJXhtbTJcblx0IiAvKiB4bW0yID0gczEqYzErczMqYzMsczIqYzIrczQq
YzQgKi8KICAgICAgICAibW92aGxwcyAgICAgICAlJXhtbTIsICUleG1tN1xuXHQiIC8qIHhtbTcg
PSBzMSpjMStzMypjMyxzMSpjMStzMypjMyAqLwogICAgICAgICJwYWRkcSAgICAgICAgICUleG1t
NywgJSV4bW0yXG5cdCIgLyogeG1tMiA9IChkb24ndCBjYXJlKSxzMSpjMStzMypjMytzMipjMitz
NCpjNCAqLwogICAgICAgICJtb3ZxICAgICAgICAgICUleG1tMiwgICAgICUwXG5cdCIKICAgICAg
ICA6ICI9bSIoYWNjdW0pIDogInIiKHN0YXRlKSwgInIiKGNvZWZmcykKICAgICk7CgogICAgcmV0
dXJuIGFjY3VtOwp9CgpzdGF0aWMgaW50NjRfdCBtbHBfZG90cHJvZHVjdF9zc2U0XzYoaW50MzJf
dCAqc3RhdGUsIGludDMyX3QgKmNvZWZmcykKewogICAgaW50NjRfdCBhY2N1bSA9IDA7CgogICAg
X19hc21fXyB2b2xhdGlsZSgKICAgICAgICAibW92ZHFhICAgICAgICAgICglMiksICUleG1tMFxu
XHQiIC8qIHhtbTAgPSBjMWMyYzNjNCAqLwogICAgICAgICJtb3ZkcXUgICAgICAgICAgKCUxKSwg
JSV4bW0xXG5cdCIgLyogeG1tMSA9IHMxczJzM3M0ICovCiAgICAgICAgInBzaHVmZCAkMHgxNCwg
JSV4bW0wLCAlJXhtbTJcblx0IiAvKiB4bW0yID0gYzFjMmMyYzEgKi8KICAgICAgICAicHNodWZk
ICQweGJlLCAlJXhtbTAsICUleG1tM1xuXHQiIC8qIHhtbTMgPSBjM2M0YzRjMyAqLwogICAgICAg
ICJwc2h1ZmQgJDB4MTQsICUleG1tMSwgJSV4bW00XG5cdCIgLyogeG1tNCA9IHMxczJzMnMxICov
CiAgICAgICAgInBzaHVmZCAkMHhiZSwgJSV4bW0xLCAlJXhtbTVcblx0IiAvKiB4bW01ID0gczNz
NHM0czMgKi8KICAgICAgICAicG11bGRxICAgICAgICAlJXhtbTQsICUleG1tMlxuXHQiIC8qIHht
bTIgPSBzMSpjMSxzMipjMiAqLwogICAgICAgICJwbXVsZHEgICAgICAgICUleG1tNSwgJSV4bW0z
XG5cdCIgLyogeG1tMyA9IHMzKmMzLHM0KmM0ICovCiAgICAgICAgInBhZGRxICAgICAgICAgJSV4
bW0zLCAlJXhtbTJcblx0IiAvKiB4bW0yID0gczEqYzErczMqYzMsczIqYzIrczQqYzQgKi8KICAg
ICAgICAibW92cSAgICAgICAgICAxNiglMSksICUleG1tMVxuXHQiIC8qIHhtbTEgPSBzNXM2MDAw
MCAqLwogICAgICAgICJwc2h1ZmQgJDB4MTQsIDE2KCUyKSwgJSV4bW02XG5cdCIgLyogeG1tNiA9
IGM1YzZjNmM1ICovCiAgICAgICAgInBzaHVmZCAkMHgxNCwgJSV4bW0xLCAlJXhtbTRcblx0IiAv
KiB4bW00ID0gczVzNnM2czUgKi8KICAgICAgICAicG11bGRxICAgICAgICAlJXhtbTQsICUleG1t
NlxuXHQiIC8qIHhtbTYgPSBzNSpjNSxzNipjNiAqLwogICAgICAgICJwYWRkcSAgICAgICAgICUl
eG1tNiwgJSV4bW0yXG5cdCIgLyogeG1tMiA9IHMxKmMxK3MzKmMzK3M1KmM1LHMyKmMyK3M0KmM0
K3M2KmM2ICovCiAgICAgICAgIm1vdmhscHMgICAgICAgJSV4bW0yLCAlJXhtbTdcblx0IiAvKiB4
bW03ID0gczEqYzErczMqYzMrczUqYzUsczEqYzErczMqYzMrczUqYzUgKi8KICAgICAgICAicGFk
ZHEgICAgICAgICAlJXhtbTcsICUleG1tMlxuXHQiIC8qIHhtbTIgPSAoZG9uJ3QgY2FyZSksczEq
YzErczMqYzMrczUqYzUrczIqYzIrczQqYzQrczYqYzYgKi8KICAgICAgICAibW92cSAgICAgICAg
ICAlJXhtbTIsICAgICAlMFxuXHQiCiAgICAgICAgOiAiPW0iKGFjY3VtKSA6ICJyIihzdGF0ZSks
ICJyIihjb2VmZnMpCiAgICApOwoKICAgIHJldHVybiBhY2N1bTsKfQoKc3RhdGljIGludDY0X3Qg
bWxwX2RvdHByb2R1Y3Rfc3NlNF84KGludDMyX3QgKnN0YXRlLCBpbnQzMl90ICpjb2VmZnMpCnsK
ICAgIGludDY0X3QgYWNjdW0gPSAwOwoKICAgIF9fYXNtX18gdm9sYXRpbGUoCiAgICAgICAgIm1v
dmRxYSAgICAgICAgICAoJTIpLCAlJXhtbTBcblx0IiAvKiB4bW0wID0gYzFjMmMzYzQgKi8KICAg
ICAgICAibW92ZHF1ICAgICAgICAgICglMSksICUleG1tMVxuXHQiIC8qIHhtbTEgPSBzMXMyczNz
NCAqLwogICAgICAgICJwc2h1ZmQgJDB4MTQsICUleG1tMCwgJSV4bW0yXG5cdCIgLyogeG1tMiA9
IGMxYzJjMmMxICovCiAgICAgICAgInBzaHVmZCAkMHhiZSwgJSV4bW0wLCAlJXhtbTNcblx0IiAv
KiB4bW0zID0gYzNjNGM0YzMgKi8KICAgICAgICAicHNodWZkICQweDE0LCAlJXhtbTEsICUleG1t
NFxuXHQiIC8qIHhtbTQgPSBzMXMyczJzMSAqLwogICAgICAgICJwc2h1ZmQgJDB4YmUsICUleG1t
MSwgJSV4bW01XG5cdCIgLyogeG1tNSA9IHMzczRzNHMzICovCiAgICAgICAgInBtdWxkcSAgICAg
ICAgJSV4bW00LCAlJXhtbTJcblx0IiAvKiB4bW0yID0gczEqYzEsczIqYzIgKi8KICAgICAgICAi
cG11bGRxICAgICAgICAlJXhtbTUsICUleG1tM1xuXHQiIC8qIHhtbTMgPSBzMypjMyxzNCpjNCAq
LwogICAgICAgICJwYWRkcSAgICAgICAgICUleG1tMywgJSV4bW0yXG5cdCIgLyogeG1tMiA9IHMx
KmMxK3MzKmMzLHMyKmMyK3M0KmM0ICovCiAgICAgICAgIm1vdmRxYSAgICAgICAgMTYoJTIpLCAl
JXhtbTBcblx0IiAvKiB4bW0wID0gYzVjNmM3YzggKi8KICAgICAgICAibW92ZHF1ICAgICAgICAx
NiglMSksICUleG1tMVxuXHQiIC8qIHhtbTEgPSBzNXM2czdzOCAqLwogICAgICAgICJwc2h1ZmQg
JDB4MTQsICUleG1tMCwgJSV4bW02XG5cdCIgLyogeG1tNiA9IGM1YzZjNmM1ICovCiAgICAgICAg
InBzaHVmZCAkMHhiZSwgJSV4bW0wLCAlJXhtbTNcblx0IiAvKiB4bW0zID0gYzdjOGM4YzcgKi8K
ICAgICAgICAicHNodWZkICQweDE0LCAlJXhtbTEsICUleG1tNFxuXHQiIC8qIHhtbTQgPSBzNXM2
czZzNSAqLwogICAgICAgICJwc2h1ZmQgJDB4YmUsICUleG1tMSwgJSV4bW01XG5cdCIgLyogeG1t
NSA9IHM3czhzOHM3ICovCiAgICAgICAgInBtdWxkcSAgICAgICAgJSV4bW00LCAlJXhtbTZcblx0
IiAvKiB4bW02ID0gczUqYzUsczYqYzYgKi8KICAgICAgICAicG11bGRxICAgICAgICAlJXhtbTUs
ICUleG1tM1xuXHQiIC8qIHhtbTMgPSBzNypjNyxzOCpjOCAqLwogICAgICAgICJwYWRkcSAgICAg
ICAgICUleG1tMywgJSV4bW02XG5cdCIgLyogeG1tNiA9IHM1KmM1K3M3KmM3LHM2KmM2K3M4KmM4
ICovCiAgICAgICAgInBhZGRxICAgICAgICAgJSV4bW02LCAlJXhtbTJcblx0IiAvKiB4bW0yID0g
czEqYzErczMqYzMrczUqYzUrczcqYzcsczIqYzIrczQqYzQrczYqYzYrczgqYzggKi8KICAgICAg
ICAibW92aGxwcyAgICAgICAlJXhtbTIsICUleG1tN1xuXHQiIC8qIHhtbTcgPSBzMSpjMStzMypj
MytzNSpjNStzNypjNyxzMSpjMStzMypjMytzNSpjNStzNypjNyAqLwogICAgICAgICJwYWRkcSAg
ICAgICAgICUleG1tNywgJSV4bW0yXG5cdCIgLyogeG1tMiA9IChkb24ndCBjYXJlKSxzMSpjMStz
MypjMytzNSpjNStzNypjNytzMipjMitzNCpjNCtzNipjNitzOCpjOCAqLwogICAgICAgICJtb3Zx
ICAgICAgICAgICUleG1tMiwgICAgICUwXG5cdCIKICAgICAgICA6ICI9bSIoYWNjdW0pIDogInIi
KHN0YXRlKSwgInIiKGNvZWZmcykKICAgICk7CgogICAgcmV0dXJuIGFjY3VtOwp9Cg==
--0015175cb2ec5b6d230468070524
Content-Type: text/x-csrc; charset=US-ASCII; name="mlpdsp_altivec.c"
Content-Disposition: attachment; filename="mlpdsp_altivec.c"
Content-Transfer-Encoding: base64
X-Attachment-Id: f_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