00:45:34 -!- joshe [~joshe@opal.elsasser.org] has quit [Ping timeout: 271 seconds] 00:45:51 joshe [~joshe@opal.elsasser.org] has joined #sbcl 01:13:17 -!- nyef [~nyef@pool-70-109-134-127.cncdnh.east.myfairpoint.net] has quit [Quit: G'night all.] 01:15:52 -!- attila_lendvai [~attila_le@catv-89-133-171-82.catv.broadband.hu] has quit [Ping timeout: 252 seconds] 01:34:34 -!- Blkt [~user@dynamic-adsl-94-37-238-79.clienti.tiscali.it] has quit [Quit: Error: do not makunbound t please] 01:48:19 rbarraud__ [~rbarraud@118-92-15-104.dsl.dyn.ihug.co.nz] has joined #sbcl 02:56:14 -!- rbarraud__ [~rbarraud@118-92-15-104.dsl.dyn.ihug.co.nz] has quit [Ping timeout: 276 seconds] 03:17:18 JonSmith [~jon@c-98-229-249-43.hsd1.ma.comcast.net] has joined #sbcl 03:39:08 -!- stassats [~stassats@wikipedia/stassats] has quit [Ping timeout: 276 seconds] 04:13:03 rbarraud [~rbarraud@118-92-15-104.dsl.dyn.ihug.co.nz] has joined #sbcl 04:41:17 -!- JonSmith [~jon@c-98-229-249-43.hsd1.ma.comcast.net] has quit [Quit: Leaving.] 04:45:37 JonSmith [~jon@c-98-229-249-43.hsd1.ma.comcast.net] has joined #sbcl 05:00:01 -!- JonSmith [~jon@c-98-229-249-43.hsd1.ma.comcast.net] has quit [Quit: Leaving.] 06:19:37 tcr [~tcr@cpc1-bour2-0-0-cust414.15-1.cable.virginmedia.com] has joined #sbcl 06:25:31 tcr1 [~tcr@cpc5-bour5-2-0-cust340.15-1.cable.virginmedia.com] has joined #sbcl 06:28:53 -!- tcr [~tcr@cpc1-bour2-0-0-cust414.15-1.cable.virginmedia.com] has quit [Ping timeout: 245 seconds] 07:04:20 -!- tcr1 [~tcr@cpc5-bour5-2-0-cust340.15-1.cable.virginmedia.com] has quit [Quit: Leaving.] 07:29:26 -!- rbarraud [~rbarraud@118-92-15-104.dsl.dyn.ihug.co.nz] has quit [Ping timeout: 276 seconds] 07:32:26 tcr [~tcr@cpc5-bour5-2-0-cust340.15-1.cable.virginmedia.com] has joined #sbcl 07:36:23 -!- cmm [~cmm@bzq-79-181-202-240.red.bezeqint.net] has quit [Ping timeout: 255 seconds] 07:37:16 cmm [~cmm@bzq-79-181-202-240.red.bezeqint.net] has joined #sbcl 07:55:01 Krystof [~csr21@84-51-132-95.christ977.adsl.metronet.co.uk] has joined #sbcl 07:55:01 -!- ChanServ has set mode +o Krystof 08:01:23 rbarraud [~rbarraud@202-180-88-252.callplus.net.nz] has joined #sbcl 08:30:01 nikodemus [~nikodemus@cs181199216.pp.htv.fi] has joined #sbcl 08:30:01 -!- ChanServ has set mode +o nikodemus 10:09:38 attila_lendvai [~attila_le@catv-89-133-171-82.catv.broadband.hu] has joined #sbcl 10:25:15 How can I make two vop translation for a single known name, one of which accepts a tagged fixnum, and the other untagged number - and have the compiler select the appropriate one? 10:26:03 Now it insists on auto-untagging the number for some reason. 10:26:37 this is where the cost comes in 10:27:06 Shouldn't auto-untagging cost something? 10:27:28 so when the costs of the operation itself are the same, the matching one is selected? 10:28:00 -!- rbarraud [~rbarraud@202-180-88-252.callplus.net.nz] has quit [Ping timeout: 252 seconds] 10:28:31 not 100% sure 10:28:54 move vops have costs too 10:29:05 in theory it should add up the paths to perform a given operation 10:29:20 nathan or paul would know better, but IIRC there is some fundamental issue in accounting for untagging costs 10:30:44 Also, why is check-operand-type-scs called only when the vop translates something? 10:31:44 Is there some place I can trace to see why the wrong op is selected? 10:34:50 find-template-for-ltn-policy / find-template / is-ok-template-to-use is what i tend to look at 10:35:38 but might be wrong for your needs -- my problem is usually "why doesn't this pick up *any* of the vops?" 10:37:43 With untagging the code looks very silly, it effectively does sar 3, then immediately shl 4 10:44:14 you might also want to look at get-operand-info 10:44:34 and its callers 11:05:17 Are tagged fixnums always any-reg on x86-64? 11:07:50 stassats [~stassats@wikipedia/stassats] has joined #sbcl 11:08:42 i think they're always descriptor-reg 11:08:46 From a brief look through the code it seems that moves might not be accounted in the cost when the op is selected 11:08:47 not sure 11:11:03 could be 11:14:39 add-representation-costs does look at move vops too, but special cases them somewhat 11:26:23 That seems to be used for tn selection, while vops are chosen purely from their cost and argument primitive type matching. 11:29:11 hm, yes 11:30:34 So I had to make the tagged vops revert to the untagged mode if the SC type is signed-reg 11:30:56 But generated code is definitely improved: http://paste.lisp.org/display/114633#1 11:31:04 do you have something i can pull so i can poke at it directly. i have a vague idea 11:31:30 ? 11:33:12 do you have a git repo? i'd like to use your test-case for looking into the interaction between representation and vop selection 11:33:55 (i'm just being lazy -- i could just a well try to find a couple of existing vops with the same issue, or cook something up myself...) 11:34:26 wait a sec, I'll push my latest changes 11:39:03 sbcl code: http://github.com/angavrilov/sbcl/commits/sse/ 11:39:40 test file: http://github.com/angavrilov/ecl-sse/blob/master/contrib/x86-sse/test-sfmt.lisp (the code is from the gen-rand-all function) 11:39:52 however, I've tweaked the vops to work as expected 11:40:16 to revert to the bad state, it is necessary to remove signed-reg from /tag vops (in the latest commit changes), and change :generator 3 to :generator 4 11:43:53 thanks 12:12:07 -!- stassats [~stassats@wikipedia/stassats] has quit [Ping timeout: 240 seconds] 12:37:19 -!- attila_lendvai [~attila_le@catv-89-133-171-82.catv.broadband.hu] has quit [Ping timeout: 252 seconds] 12:57:16 -!- tcr [~tcr@cpc5-bour5-2-0-cust340.15-1.cable.virginmedia.com] has quit [Quit: Leaving.] 13:01:07 tcr [~tcr@cpc5-bour5-2-0-cust340.15-1.cable.virginmedia.com] has joined #sbcl 13:43:18 stassats [~stassats@wikipedia/stassats] has joined #sbcl 15:00:59 -!- tsuru [~charlie@c-174-50-217-160.hsd1.tn.comcast.net] has quit [Remote host closed the connection] 15:10:51 -!- nikodemus [~nikodemus@cs181199216.pp.htv.fi] has quit [Quit: This computer has gone to sleep] 15:24:37 nikodemus [~nikodemus@cs181199216.pp.htv.fi] has joined #sbcl 15:24:37 -!- ChanServ has set mode +o nikodemus 16:15:45 -!- nikodemus [~nikodemus@cs181199216.pp.htv.fi] has quit [Quit: This computer has gone to sleep] 16:19:32 nikodemus [~nikodemus@cs181199216.pp.htv.fi] has joined #sbcl 16:19:32 -!- ChanServ has set mode +o nikodemus 16:38:04 -!- cmm [~cmm@bzq-79-181-202-240.red.bezeqint.net] has quit [Ping timeout: 265 seconds] 16:38:40 cmm [~cmm@bzq-79-181-202-240.red.bezeqint.net] has joined #sbcl 16:41:17 -!- nikodemus [~nikodemus@cs181199216.pp.htv.fi] has quit [Quit: This computer has gone to sleep] 16:55:22 hargettp [~anonymous@pool-71-174-140-140.bstnma.east.verizon.net] has joined #sbcl 17:00:08 hmm, the GCC version seems a bit more optimal, but, overall, quite close: http://paste.lisp.org/display/114633#2 17:07:06 rmarynch [~roman@bras-4-ge-62.122.200.230.utm.if.ua] has joined #sbcl 17:58:03 -!- rmarynch [~roman@bras-4-ge-62.122.200.230.utm.if.ua] has quit [Quit: Leaving] 18:12:41 yeah. representation selection really sucks for fixnum/untagged. 18:13:17 I haven't found any problem similar to it in the literature so far. 19:11:18 JonSmith [~jon@c-98-229-249-43.hsd1.ma.comcast.net] has joined #sbcl 19:19:57 some of the work xavier leroy did on representation selection for unboxed floats looks like it ought to be applicable, but I haven't been able to wade through the equations 19:20:45 I think the real problem is that we should have six different vops for {fixnum,signed,unsigned}x{var,constant}. they should all be a single vop and then representation selection could do a better job 19:20:58 er, *shouldn't* have 19:22:45 tsuru [~charlie@c-174-50-217-160.hsd1.tn.comcast.net] has joined #sbcl 19:24:48 (actually, it's "just" a quadratic assignment problem) 19:28:52 ILTWYS"J" 19:31:59 although, really, tree decomposition etc., and it's probably usually possible to derive a realistic dynamic programming schedule (but I have a real thesis to work on, and we're getting uncomfortably close to it ;) 22:11:03 nikodemus [~nikodemus@cs181199216.pp.htv.fi] has joined #sbcl 22:11:03 -!- ChanServ has set mode +o nikodemus 22:50:02 -!- nikodemus [~nikodemus@cs181199216.pp.htv.fi] has quit [Quit: This computer has gone to sleep] 23:59:19 -!- stassats [~stassats@wikipedia/stassats] has quit [Ping timeout: 252 seconds]