Index

Show enters and exits. Hide enters and exits.

00:02:52codebrulee enters the room.
00:02:52bricolage leaves the room.
00:07:26gilesgoatboy leaves the room.
00:07:41mutle_ leaves the room.
00:08:35CIA-20* Move the haphazard __ivars__ into the object header; d5d35be - Evan Phoenix
00:08:43mutle leaves the room.
00:09:55CIA-20* Remove absent functions; 515449e - Evan Phoenix
00:13:33imajes_ enters the room.
00:13:37enebo enters the room.
00:18:21benny enters the room.
00:29:28yroc leaves the room.
00:31:16nari leaves the room.
00:38:24evanoh oh.
00:38:36evanI think i'm going to juggle the header a little
00:38:42evanand make things cleaner.
00:38:45blakewatters leaves the room.
00:39:19evanwho's around?
00:39:21brixenme
00:39:24drbrainme
00:39:26evani need to bounces names around
00:39:26evanok
00:39:31blakewatters enters the room.
00:39:31evanTypeInfo blows as a name
00:39:36brixenagreed
00:39:44evanit says about as much as "meat sandwich"
00:39:52brixen:)
00:40:34evanhere's what it is, you can help me think of a better name
00:40:56evanthere is one for every kind of object layout in the system
00:41:12evana particular object layout is what i've been calling a type
00:41:36evangive a type, you can get a TypeInfo about that describes that type
00:41:40evanand call methods on it
00:41:59evani've been saying that it "shadows" the Ruby class of
00:42:02evans/of//
00:42:13evanproviding VM specific operations
00:42:37evanI wish we didn't need them
00:43:22evanbut they're a necessary evil to be able to organize things polymorphicly
00:43:50drbrainthey're metadata
00:44:59evanwell, they're metafunctionality
00:45:03evanbut yes.
00:45:06brixenhrm, given what it is, TypeInfo isn't that terrible I suppose
00:45:38brixenlooking at synonyms for information, knowledge, data
00:47:01evanI could just call it Type
00:47:06evani thought about that originally
00:47:13evanbut that seems like it would cause more confusion
00:47:18brixenare you hitting a problem with it?
00:47:33evanno
00:47:34brixenI'd suggest leaving it for now if not
00:47:36evanjust been staring at it today
00:47:38evanok
00:47:54drbrainyeah
00:48:07drbrainTypeInfo sounds like it's minimally terrible
00:48:39evanok
00:48:43evanwell, i've planted the seed now
00:48:55evanmaybe one of you guys will come up with a better name
00:49:27brixensure, it can be difficult if you're just see it
00:49:35brixenit was one of my Q's in that list
00:49:45brixenbut given a little doc about it, it's not terrible
00:49:54brixens/see/seeing/
00:50:27evanok, question 2:
00:50:39evanis 2 ** 18 (262144) too small for the max object size?
00:50:57drbrainwhat is a max object size?
00:51:01drbrainhow many slots?
00:51:05evanyeah
00:51:08evanactually, it would be 524287
00:51:11evan2 ** 19 - 1
00:51:14evan18 full bits
00:51:20evanmax slots
00:51:26evanthe only thing I can think it would impact is Array
00:51:30drbrainwhy would it need to be bigger than, say, 32?
00:51:32evansince Tuple uses the slots directly
00:51:45evandrbrain: for Tuple
00:51:54evanand String
00:52:02evanwell, ByteArray
00:52:21evanthe backends for Array and String
00:52:32binary42 enters the room.
00:52:36evanif it were 32, you could only have an array with 32 elements
00:52:43evanunless we come up with a chunking storage for Arary
00:52:49evan(which we should eventually anyway)
00:53:04brixenyeah, Array will need some work
00:53:13evanbut barring that
00:53:22drbrainthen I think we should use 32
00:53:29evanseems like 524287 elements would be an ok limitation?
00:53:34evandrbrain: 32 slots max?
00:53:36drbrainsince I've made Arrays with a million or more elements before
00:53:37evanor 32bits?
00:53:46evanoh wait
00:53:53evanwere you meaning 32bits the whole time?
00:53:58drbrainit seems like 500k slots is temptation to do bad things
00:54:09drbrainso I say we arbitrarily make it small to force us to Do It Right
00:54:13evanand 4B isn't?
00:54:19evanso, you do mean 32 slots
00:54:25evanplease answer.
00:54:34drbrainI through 32 slots out there abritrarily
00:54:48brixenheh
00:54:55brixenevan: here's your chance!
00:54:59drbrainit seems that the only valid reason for having it be 500k slots is "because we are lazy"
00:55:00brixenthrew?
00:55:11evandrbrain: sure
00:55:11drbrainsorry, threw
00:55:19evanit's 32bits (ie, 4G) now
00:55:24evanbut we can't actually support an object that big
00:55:30evanwell, we could
00:55:34evanbut the machine would tip over before that.
00:55:49brixenseems that Array and String should be considered separately
00:55:53evanlet me check what the squeak max is
00:56:04imajes_ leaves the room.
00:56:07brixenI believe the specs for Array on 64bit MRI allow you to allocate as much memory as possible
00:56:11dgtizedwhat about renaming TypeInfo to ClassInfo -- it seems like it has the same problems with using the name type as ruby does
00:56:30evandgtized: hm..
00:56:34evanbrixen: true
00:56:55dgtizedor am I misunderstanding it's relationship to classes
00:56:56AndrewO leaves the room.
00:57:36drbrainright now the max Array size in 1.8 trunk is 1073741824
00:57:40drbrainfor 32 bit
00:57:56evandrbrain: and you make one
00:57:58drbrain#define ARY_MAX_SIZE (LONG_MAX / sizeof(VALUE))
00:58:03drbrainif I read that right
00:58:03evanright
00:58:06evanthats 4G of memory
00:58:12evanbecause sizeof(VALUE) == 4
00:58:24evanso it's 1G of VALUE's in order
00:59:52drbrainmy main objection is that allowing a lot of slots tempts us to take shortcuts
01:00:11drbrainhow is the slot count currently determined?
01:00:13evanwell, have we been taking shortcuts up to now?
01:00:24evanother than Tuple and ByteArray
01:00:27evanstaticly, at compiletime
01:00:30drbrainthe Array thing seems like a shortcut
01:00:52evanyou mean just using a single Tuple as flat storage is a shortcut?
01:00:57evanit's certainly the simplest way
01:01:02evani'm not sure i'd call it shortcut
01:01:12drbrainI meant, why is it 500k and not a long or something?
01:01:18evanit's not.
01:01:23evanit's a long now.
01:01:28brapse leaves the room.
01:01:29evani'm trying to move stuff around in the header
01:01:29drbrainok
01:01:38evanand was considering reuse a few bits for flags and stuff
01:01:41evanjust cleaning it up
01:01:47evantrying to decide if we needed the full 32bits
01:01:53brixenI don't think so
01:01:54drbrainah, ok
01:02:04brixenthe Array limitation has to be addressed a different way
01:02:11brixenso, I'd say use the bits
01:02:27evanok
01:02:43drbrainhow many bits are otherwise allocated, and would it be a problem if we wanted to use more bits?
01:02:46brixenwe're going to namespace Tuple anyway, right?
01:02:55brixenso, it shouldn't actually be in Ruby code
01:03:02evandrbrain: if we want to use more bits, we can just reshuffle the header again
01:03:07evandrbrain: and use more header space
01:03:08brixenand we can modify how Array works under the covers
01:03:16evanshuffling the header isn't hard
01:03:19evanit's just trade-offs
01:03:51evanbrixen: we've going to refactor Tuple out of the common code, yes.
01:03:57evaninto the Rubinius specific stuff
01:03:58brixencool
01:04:02drbrainI don't see why we don't keep using long then
01:04:08drbrainfor number of header fields
01:04:46evandrbrain: you don't see why we'd continue if we're going to move stuff around in Array?
01:06:02drbrainif we can use a significant fraction of a long's worth of slots for Array, (like 1.8 does), then why should we limit ourselves to 500k?
01:06:17drbrainI see two alternatives, use a lot of slots, or use very few
01:06:48drbrainthe middle ground doesn't look very fruitful
01:07:01evani consider 500k being a lot
01:07:03evando you?
01:07:09evanor do you consider that the middle ground
01:07:20drbrainI consider that middle ground
01:07:30drbrainsince 500k isn't a lot of Array slots
01:07:53evanwhat would you consider a lot?
01:07:58evanjust trying to get your guage
01:08:00drbrainwith few we run into the walls quickly and find robust solutions
01:08:06drbraina long's worth
01:08:13evanI mean, MRI tips over if you have a 1G array as is
01:08:24evanso you could say it doesn't really support it either.
01:08:25drbrainyes
01:08:44drbrainobviously there's the LONG_MAX / sizeof(long) limit
01:08:53drbrainbut that's defined by hardware
01:09:04evanoh ok.
01:09:10evanhere's the 2 definitions
01:09:17evanshould slots be physical max or functional max?
01:09:27evanMRI's number is physical max
01:09:37brixenMRI's number is an implementation limitation
01:09:55brixenMRI chooses to impl it as a single array
01:10:00evanright
01:10:12evanI think that we'll decide soon that we need Array to be sparse anyway
01:10:16evanusing a simple chunking algo
01:10:17brixenyep
01:10:19brixenwe should
01:10:29brixenwhat would you use the bits for evan ?
01:10:32evanin which case, the need for a huge Tuple goes away
01:10:37brixenright
01:10:50evanwe could have a chunked String to
01:10:53drbraindo we only use huge tuples for Array?
01:10:57evanyep
01:11:11evaneverything else is like Tuples of 4 or 5 slots
01:11:20drbrainand I'm guessing huge ByteArrays for String
01:11:21evanbasically used as a small, cheap Array
01:11:26evandrbrain: exactly.
01:11:57nari enters the room.
01:12:33drbrainI say we move towards the using more like 8 bits for slot numbers
01:12:38drbrain-the
01:12:40jbarnette leaves the room.
01:12:43evanyeah
01:12:46evanI like that.
01:13:04fizx enters the room.
01:20:32evanI'm going to go for the middle ground for right now
01:20:40headiusevening
01:20:43evanand schedule a task to implement chunking in Array
01:20:48evanheadius: hey
01:21:11headiusarray chunking?
01:21:51evanheadius: we were discussing how an Array with 1M elements should be represented
01:22:21headiusdo people use arrays with 1M elements?
01:22:34evanaccidentally sometimes
01:22:51evanwell, also, what should the max object size be
01:23:08evanwhich, current, influences how large an Array can be
01:23:25evanif we implement Array's storage as chunking, that influence goes away
01:23:35headiusmmm I see
01:23:47headiusthis is embedding data in object header yes?
01:23:51headiuslike str/ary length
01:23:56evanno
01:23:58evannot really.
01:24:10evanRubinius has variable sized objects in memory
01:24:20evanthings like Tuple and ByteArray make use of that
01:24:30evanto store their data directly after the object header
01:24:50evanthe object size is how many fields it has
01:25:02headiusahh
01:25:04evanthings like Array have like 4 or 5
01:25:17evanone of them being a ref to a Tuple, which it uses for storage.
01:25:36headiusso you want to use less than 64 or 32 bits for length to shrink that size?
01:26:08evanthe size of the count in the header, yes.
01:26:21evanso I can use it for something else
01:26:24headiusis that really a big enough savings to matter?
01:26:59evanif we have 50_000 objects, thats an extra 200k
01:27:07dfg59 leaves the room.
01:27:09headius200k isn't much
01:27:20evan*shrug*
01:27:32evanit's an issue we've needed to deal with anyway
01:27:42evangiant Array's
01:28:32fizx leaves the room.
01:28:52brixenand there's even papers on dealing with such things: http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.36.9607
01:29:07yugui enters the room.
01:29:13evanack
01:29:21evanmaking this change blows up the 64bit alignment.
01:29:41evanoh, i can fix that easy.
01:29:42evannm.
01:29:42evan:)
01:30:50headiusbrixen: dealing with what things
01:31:01brixenheadius: see the link
01:31:15headiusahh, sorry, new citeseer layout confused me
01:31:22brixenyeah, it's weird :)
01:31:28brixenciteseer beta heh
01:31:29headiusI just saw "3, and"
01:32:14headiusyeah, I played with some sparse arrays for dispatch tables a while back
01:32:29evanhm, this change cleans up as<> too
01:33:13headiusjust seems like an unusual change to consider, but I don't fully understand all your motives
01:33:30lopex leaves the room.
01:34:11evanwhich?
01:34:27nari leaves the room.
01:35:07headiusI suppose both chunked arrays and non-integer array size
01:35:15headiuser non-int
01:35:43evanhuh?
01:35:50headiusnon-32-bit-always
01:35:52evannot sure what ya mean by the later
01:37:27Defiler leaves the room.
01:38:06headiusmaybe I'm not understanding how this saves you 200k or why that's significant
01:38:41headiuseliminating a 4-byte array size seems like it would only help array object size, so perhaps if you had 50k arrays you'd save that
01:39:33evanit's not Array
01:39:38evanyou're not getting it.
01:39:51evanit's the fundemental object size
01:40:14headiusoh, so this is the number of slots you have for the object's data?
01:40:21evanthink about it as 'how big can a single, contigious object be'
01:40:29evanheadius: right.
01:41:19headiusisn't that used primarily by rubinius core classes though? and probably no more than a handful of slots ever?
01:41:32evanyep.
01:41:33headiuslike why would there be more than 256 slots ever
01:41:41evan(this is the discussion we had 20 minutes ago)
01:41:55headiuswell, good for you :)
01:42:01evanthe only thing need more than, say 256, is Tuple and ByteArray
01:42:18evanin the current setup, a flat Tuple is used as an Array's storage
01:42:22evanand ditto for String to ByteArray
01:42:34headiusok, I see drbrain asked that as well
01:42:40evanyeah
01:42:41evanif you can
01:42:42evanscroll up
01:43:12imajes_ enters the room.
01:43:31jtoy enters the room.
01:43:42ezmobius leaves the room.
01:43:44headiuswhy do tuple and bytearray need more
01:43:59headiusI don't see that mentioned
01:44:05evanyou'd like an Array with more thon 256 elements
01:44:12evanor a String with more than 1024 bytes
01:44:38headiuswhy isn't the physical array a pointer to an array
01:44:51evanit is.
01:45:03evanyou mean a pointer into random C heap memory?
01:45:06evannot GC managed memory?
01:45:11evanrubinius doesn't do that.
01:45:19evanit doesn't handle Array and String the way MRI does
01:45:25evanby having the storage point of into C heap
01:45:26headiuswell, neither does JVM, but an object with an array in it is not the size of that array
01:45:43evanheadius: Rubinius has no primitive types
01:45:44headiushave the GC allocate the array and provide a reference to it for you
01:45:47evanand thus no 'raw' Array.
01:45:54evaner. s/Array/array/
01:45:57headiusand access array elements through the reference
01:46:04evanbut that thing still has a max size
01:46:07evanit's the same thing really
01:46:29evanif you must, think of our Tuple like a java array.
01:46:43evanin memory, it's almost exactly the same
01:46:54evanexcept a Tulpe has a header on it to say what it is, and how big it is.
01:47:13headiusyes, java arrays have the same thing
01:47:21headiusthey are still full Objects
01:47:34evanwhat do they say their class is?
01:47:50headiusthe array type of that class
01:47:58headiusarray types are instantiated at runtime as needed
01:48:31evananyways
01:48:33headiusbut that's more an internal detail
01:48:43evani'm going to head home
01:48:46evanbe back on in a bit.
01:48:53headiusso your problem is that tuple and bytearray are also presented to ruby code
01:48:58headiusso they need a full header appropriate for ruby
01:49:09evaneverything does, yes.
01:49:16evanthats not really the problem though.
01:49:20evanat least how I see it.
01:49:20headiusand thus you can't reduce them to non-ruby-compatible internal data structures with their own layout
01:49:41evanand we wouldn't want to
01:49:45evanthey're a building block
01:49:48evanplain and simple.
01:50:00headiuswhy not have a building block that's not a ruby object
01:50:04evanthey're supposed to be built upon to create more powerful abstractions
01:50:08evanheadius: whats the point?
01:50:14evanwhat does that buy us?
01:50:31headiusto avoid having to fiddle with object sizes at the ruby level just to accommodate arbitrary-length arrays
01:51:04evanwell
01:51:11evan1) object size isn't fiddle at the ruby level.
01:51:11headiusyou could have a byte slot count for everything if you didn't have to deal with just a handful of types that want large slot counts
01:51:31yugui leaves the room.
01:51:34evanI think your abstraction makes it more complicated
01:51:37evanrather than less.
01:51:58headiusI don't think so...tuple and bytearray are already implemented mostly in C/++ aren't they?
01:52:04evanno
01:52:12evani mean
01:52:27evanthey only have a couple of operations
01:52:30evanwhich i guess are in C
01:52:37evanbut we're talking like 3 methods each
01:52:42evananyways
01:52:46evani've got get home.
01:52:47evanbbiab.
01:52:57headiusso why does it matter whether they store their data in the tuple/bytearray object itself or as a handle to data of arbitrary size elsewhere
01:52:59ijcd enters the room.
01:53:02headiusok, ttfn
01:56:38edwardam enters the room.
01:56:51ijcd_ enters the room.
01:57:08c0sin leaves the room.
01:59:02trythil enters the room.
02:03:43yugui enters the room.
02:05:33trythil_ enters the room.
02:06:48yugui_ enters the room.
02:12:40ijcd leaves the room.
02:13:23jackdempsey leaves the room.
02:14:23yugui leaves the room.
02:17:00nicksieger leaves the room.
02:20:04trythil leaves the room.
02:20:50nicksieger enters the room.
02:23:54imajes_ leaves the room.
02:25:34evanheadius: so, I think what I failed to mention is how the object size/header interacts with the GC
02:25:57evanI see what you were talking about
02:25:59evanthat could work
02:26:48zenspider'sup my bitches?
02:26:59evanhe lives!
02:27:21zenspiderbarely
02:27:35zenspiderI don't remember if I msg'd you
02:27:44evanyou did earlier today
02:27:51zenspiderI'm not an alternate, so I've got deliberations tomorrow...
02:27:58zenspiderbut I don't think it'll take very long
02:27:58evanoh yay!
02:28:03zenspider"sadly"
02:28:30headius leaves the room.
02:28:43evanah
02:28:53evanwell, you can tell us about it once it hits the papers
02:28:58evanor whatever the rule is
02:30:20zenspiderI'll be able to talk about it once we're done with deliberations... I'm guessing tomorrow, but *shrug*
02:33:38evanok, i'm off to a bbq
02:33:40evansummer style.
02:34:32obvio171 enters the room.
02:35:01zenspidernom nom nom
02:42:50qrush enters the room.
02:46:04jackdempsey enters the room.
03:04:56benburkert leaves the room.
03:05:53benburkert enters the room.
03:06:42benburkert leaves the room.
03:07:23iamclovin enters the room.
03:09:18c0sin enters the room.
03:12:18c0sin leaves the room.
03:16:18iamclovin leaves the room.
03:16:48shayarnett enters the room.
03:23:41blakewatters leaves the room.
03:25:53codebrulee leaves the room.
03:27:47yugui_ leaves the room.
03:59:19benburkert enters the room.
04:01:25trythil_ leaves the room.
04:03:14enebo leaves the room.
04:06:54yugui enters the room.
04:13:20yugui leaves the room.
04:26:27keisukefukuda enters the room.
04:34:18ijcd_ leaves the room.
04:34:20shayarnett leaves the room.
04:39:07ezmobius enters the room.
04:40:16AndrewO enters the room.
04:44:15nicksieger leaves the room.
04:54:59Yurik enters the room.
04:59:27edwardam leaves the room.
05:11:05keisukefukuda leaves the room.
05:14:55benburkert leaves the room.
05:16:15antares enters the room.
05:22:14nari enters the room.
05:22:36yugui enters the room.
05:24:40guitsaru enters the room.
05:28:14obvio171 leaves the room.
05:29:56qrush leaves the room.
05:36:25trythil enters the room.
05:43:08gilesgoatboy enters the room.
05:47:30gilesgoatboy leaves the room.
05:47:52dbussinkdgtized: still there?
05:48:07dbussinkyou had a question about all the Integer::from versions?
05:48:30evandbussink: yo
05:48:55evandbussink: we took the native_int version out
05:49:02dbussinkyeah i saw it
05:49:05evanbecause, as you saw, it conflicts with either int or long
05:49:20evanand it depends on the platform which it conflicts with
05:49:23dbussinkseems fine to me
05:49:28evanso since native_int is either or anyway, should be fine
05:49:29evanyeah
05:49:31dbussinkit'll work out itself now
05:49:51evanyep
05:51:52evanI like the look a lot better though
05:51:55evangood job!
05:52:35dbussinkhopefully it helps against Defiler's confusion too ;)
05:54:51AndrewO leaves the room.
05:58:31nicksieger enters the room.
06:06:29fbuilesv enters the room.
06:14:53guitsaru leaves the room.
06:21:14lchin enters the room.
06:30:11benburkert enters the room.
06:40:55trythil_ enters the room.
06:42:41benny leaves the room.
06:46:23jtoy leaves the room.
06:46:35jtoy enters the room.
06:52:21jayWHY_ enters the room.
06:57:17jackdempsey leaves the room.
06:57:32trythil leaves the room.
06:58:18jayWHY leaves the room.
07:01:57benny enters the room.
07:12:23benny leaves the room.
07:12:38benny enters the room.
07:18:31thehcdreamer enters the room.
07:20:48benburkert leaves the room.
07:22:35gnufied leaves the room.
07:43:00rubuildius_amd64 leaves the room.
07:48:15lchin leaves the room.
07:49:39krsh enters the room.
07:54:27w1rele55 enters the room.
08:02:20yroc enters the room.
08:04:03BlackEdder enters the room.
08:04:33BobFunkasdas leaves the room.
08:06:32dysinger leaves the room.
08:08:01mutle enters the room.
08:09:53BlackEdder leaves the room.
08:10:05BlackEdder enters the room.
08:11:26trythil enters the room.
08:14:44antares leaves the room.
08:15:17antares enters the room.
08:18:33michalw enters the room.
08:18:50mutle__ leaves the room.
08:21:54Arjen_ enters the room.
08:26:27trythil_ leaves the room.
08:39:16octopod enters the room.
08:42:36jayWHY_ leaves the room.
08:46:53trythil leaves the room.
08:52:29yroc leaves the room.
09:07:06Maledictus enters the room.
09:10:24keisukefukuda enters the room.
09:15:02NoKarma enters the room.
09:28:38headius enters the room.
09:34:17lchin enters the room.
09:43:13ezmobius leaves the room.
09:44:53Arjen_ leaves the room.
09:57:11benny leaves the room.
10:26:49headius leaves the room.
10:37:53scoopr leaves the room.
10:41:30michalw leaves the room.
10:59:46chris2 enters the room.
11:02:15nari leaves the room.
11:06:30mutle_ enters the room.
11:23:36mutle leaves the room.
11:26:30yugui leaves the room.
11:40:45krsh leaves the room.
11:43:15jtoy leaves the room.
11:48:32scoopr enters the room.
11:54:22lchin leaves the room.
12:04:23Maledictus leaves the room.
12:04:23w1rele55 leaves the room.
12:04:23rubuildius_ey64 leaves the room.
12:04:23evan leaves the room.
12:04:23josb leaves the room.
12:04:23explody leaves the room.
12:04:51Maledictus enters the room.
12:04:51w1rele55 enters the room.
12:04:51josb enters the room.
12:04:52rubuildius_ey64 enters the room.
12:04:52evan enters the room.
12:04:52explody enters the room.
12:17:23w1rele55 leaves the room.
12:20:50kota enters the room.
12:22:35thehcdreamer leaves the room.
12:23:33thehcdreamer enters the room.
12:24:48botanicus enters the room.
12:37:25thehcdreamer leaves the room.
12:38:28thehcdreamer enters the room.
12:56:26thehcdreamer leaves the room.
12:58:04thehcdreamer enters the room.
13:00:41benny enters the room.
13:01:25thehcdreamer leaves the room.
13:03:05antares leaves the room.
13:51:30keisukefukuda leaves the room.
14:10:02antares enters the room.
14:20:20Fullmoon enters the room.
14:24:13blakewatters enters the room.
14:32:30trythil enters the room.
14:33:37foysavas enters the room.
14:34:47trythil leaves the room.
14:36:04moofbong enters the room.
14:44:54binary42 leaves the room.
14:47:53AndrewO enters the room.
15:00:50Fullmoon leaves the room.
15:02:49benburkert enters the room.
15:03:07ch0wda enters the room.
15:06:37wmoxam enters the room.
15:08:32pauldix enters the room.
15:15:03binary42 enters the room.
15:20:04fbuilesv leaves the room.
15:25:08benny leaves the room.
15:30:35BobFunk enters the room.
15:36:26edwardam enters the room.
15:36:41foysavas leaves the room.
15:37:09nari enters the room.
15:49:06lorenzod8n enters the room.
16:13:39krsh enters the room.
16:16:28edwardam leaves the room.
16:17:07joachimm_ enters the room.
16:20:20bricolage enters the room.
16:28:08Defiler enters the room.
16:37:41joachimm leaves the room.
16:38:07joachimm_ leaves the room.
16:45:55dfg59 enters the room.
16:49:53keisukefukuda enters the room.
17:07:15evanwonderful
17:07:37evansomeone in Russia stole my credit card number. :/
17:07:55loopouch
17:09:35evanand they changed $2k
17:11:47brixenyikes
17:11:55benburkert leaves the room.
17:13:54DefilerIf they bought a bunch of Apple products and VM books you are going to have a hard time proving it :)
17:14:30evannope
17:14:32evanRussian Diamonds.
17:14:36evanpretty easy to tell.
17:14:53evansince I've 1) never been to Russia, and 2) Don't be jewelry, esp. diamonds
17:15:11Defilerheh
17:16:55jbarnette enters the room.
17:25:17atok leaves the room.
17:27:23foysavas enters the room.
17:28:07brixenevan: so, a bit of thinking aloud in code: http://gist.github.com/5075
17:28:42brixenI looked at using multimap, but you can't get all the keys. you get any one of the keys if there are multiple
17:29:07brixenevan: so, my idea is a single map where the values can be chained. and the hash is the key
17:29:18brixenthe value has the symbol, string, and next*
17:31:20evanone sec.
17:31:21evansorry.
17:34:48evanbrixen: ok
17:34:55evani've got a couple of notes
17:35:07brixenk
17:35:16evan1) probably shouldn't use std:map
17:35:21evanit's not a hash table at all
17:35:26evanit's a balanced tree
17:35:44brixenk
17:36:20evanalso
17:36:26evanfor this first cut
17:36:39evanlets just use the same data structure setup / algo as we did before
17:36:51evanie, the table contains a hash and an array
17:36:56evanthe hash is used for string => id
17:37:00evanthe array is used for id => string
17:37:00brixenwell, in that case, what's the reason to switch?
17:37:07brixenwhy not just replace Hash with LT?
17:37:19evanit's recursive.
17:37:23evanyou can't have strings for keys
17:37:28evanunless you symbolize them
17:37:32brixenah yeah
17:37:34evanbut you need the symbol table
17:37:35evanoh crap.
17:37:36evan:)
17:37:52brixenso, you don't like chaining the values?
17:37:57brixenseems simpler
17:38:05evanI don't get what ya mean
17:38:12evanjust chaining like a chaining hash table?
17:38:14jbarnetteevan: i just started reading, and this is probably irrelevant, but the STL has a pretty comprehensive set of balanced tree stuff
17:38:24evanjbarnette: we don't want a balanced tree
17:38:28evanwe want a hash table.
17:38:36jbarnetteevan: guess i should scroll up :)
17:38:40brixenevan: ok, so what do I use for a DT?
17:38:52evanwhats a DT?
17:38:57brixendata type
17:38:59brixenstructure
17:39:34michalw enters the room.
17:39:37brixeni.e. we're removing Hash, so what do I replace it with?
17:39:43brixenI thought that was the point of this?
17:39:58evanwell, thats why I was saying, for now, we move it into C++
17:40:15brixenyou want me to impl a C++ only Hash?
17:40:28evanor find one.
17:40:32evanas a first cut though
17:40:35evanyou can use std::map
17:41:15evanbut we'll need to replace it's usage with a real hash table
17:41:17loopthere is tr1::unordered_map
17:41:26evanloop: i've never been able to get it to work
17:41:38enebo enters the room.
17:41:42evanloop: so if you have skills related to that, i'm all ears.
17:41:59loopevan: i think i have some source code that uses it, i'll check it when i get home
17:42:00brixenevan: ok, I'll take a look at it when I return from class
17:42:13evanok
17:42:30evanbrixen: for a first cut, the easiest way to be to port the algo we currently use
17:42:34evanusing std::map and std::vector
17:42:40brixenyeah, I see that
17:42:40evanthen we can tweak and refactor from there
17:42:44brixenI'll look at unorded_map
17:42:49brixenunordered*
17:43:04evanok
17:43:18evanDefiler: was there something you wanted me to look at?
17:43:48evanDefiler: wrong (on Qnil)
17:43:53DefilerYeah. I just want to make sure I understand the impact of the __ivars__ change
17:43:57evanDefiler: Qnil in the ivars field just means it doesn't have any ivars.
17:43:59evanthats all.
17:44:05DefilerFor example, I notice that the function for 'hey do you support ivars' always returns TRUE now
17:44:07evanit doesn't mean it can't store any.
17:44:09DefilerOK
17:44:11evanyep
17:44:14evaneverything can now
17:44:18evanexcept for non-references
17:44:32evanwhich are handled specially in Object::get_ivar and Object::set_ivar
17:45:07evanthe impact is that normal classes don't have to declare an __ivars__ slot
17:45:13evaneverything gets one
17:45:49DefilerOK, dumb C++ question.. what is really happening when this is declared: typedef Fixnum* FIXNUM;
17:46:08loopDefiler: makes FIXNUM an alias for Fixnum*
17:46:11Defilersure
17:46:13keisukefukuda leaves the room.
17:46:32jbarnetteDefiler: it's purely an alias
17:46:43Defilerbut what is so special about Fixnum that it gets one of those, and (for example) Array does not
17:46:44evanit's just for looks
17:46:47DefilerOK
17:46:58evanbecause FIXNUM is an immediate
17:47:03evanand it looks strange with the * there
17:47:10evanmaking you think it points into memory
17:47:11evanwhen it doesn't
17:47:18evanit's for look and feel alone.
17:47:29Defilerand OBJECT has an equivalent typedef for the same reason, etc
17:47:48evanbecause we type it so much
17:47:56Defilerand hey, it might be a Fixnum anyway
17:47:57evanand I wanted it to feel more opaque
17:48:02evanexactly.
17:50:14antares leaves the room.
17:54:26dbussinkDefiler: more happiness for you in my last commit just now :)
17:54:52ijcd enters the room.
17:55:22Defilerdbussink: hot
17:56:47CIA-20* Copy paste woes, oops; bd6f790 - Dirkjan Bussink
17:58:49dbussinkwhy does it pick up that commit but not the previous one?
17:59:31evanCIA is weird
17:59:33evanis why.
18:00:09CIA-20* Add some additional assertions for FFI conversions; d8f190f - Dirkjan Bussink
18:00:12dbussinkDefiler: what do you think of the new more consistent api? :)
18:00:28DefilerMuch nicer
18:01:43dbussinknext step i want to do is clean up several to_ methods that convert into another type
18:01:53dbussinkto_float or to_f, to_string or to_s etc.
18:01:58dbussinkany preference?
18:02:03evanDefiler: i think the answers to those questions, btw, are covered in vm/doc/ARCH.txt
18:02:18evanwhich is yet another reason we need to get a process for exporting our docs to the web
18:02:37DefilerAah, so they are
18:02:43DefilerAnswered very clearly, in fact.
18:03:45evanalright, i'm going to head to the coffee shop
18:04:28dbussinkevan: do i have to regenerate instructions? because i changed some calls there too
18:04:38dbussinkif so, how should i do that?
18:04:42evanin instructions.rb you did?
18:04:43evanyou change
18:04:46evanyou changed, rather.
18:04:51dbussinkyeah
18:05:07evanit will do it automatically
18:05:09evanso you're fine
18:05:40dbussinkah, because i saw an instructions.o commit just after my last refactor
18:12:13shame leaves the room.
18:14:31krsh leaves the room.
18:14:46dbussinkhmm, the coverage task fails for me
18:15:19dbussinkbecause of the tmpname method that ensures the deletion of a file the coverage tool needs
18:19:21octopod leaves the room.
18:21:08evandbussink: ack.
18:21:15evanhm, it did work originally for me..
18:21:21CIA-20* Modified some wording in vm/doc/ARCH.txt; 845c6ff - Wilson Bilkovich
18:21:27evani think we're going to go have to go back to gen/ files
18:21:33evanrather than tmp
18:22:34BobFunk leaves the room.
18:38:29c0sin enters the room.
18:45:52Defilerevan: the regexp_new primitive in shotgun sets the 'klass' field on the created Regexp instance, in order to allow it to return subclasses of Regexp
18:46:04evanyep.
18:46:08Defilerevan: It looks to me like that same approach will work here.
18:46:10DefilerDoes that sound right?
18:46:12evanyep.
18:46:19evanuse SET(other, klass, blah)
18:46:22Defileryeah
18:46:42octopod enters the room.
18:47:50DefilerShould I do the additional work the primitive wants in a function that then calls Regexp::create, or should I modify create until it does everything the primitive needs?
18:48:01DefilerI ask because it is already pretty long, due to the oniguruma API
18:48:10evanup to you.
18:48:30DefilerI'll do it with a second function first and if it ends up boiling down to one line or something I will change my mind
18:49:34evanok
18:58:57benburkert enters the room.
18:59:46benburkert leaves the room.
19:02:45benburkert enters the room.
19:04:49keisukefukuda enters the room.
19:05:04BlackEdder enters the room.
19:06:14BlackEdder enters the room.
19:11:38keisukef_ enters the room.
19:11:54keisukefukuda leaves the room.
19:13:04tmornini enters the room.
19:14:22tmornini leaves the room.
19:14:26tmornini enters the room.
19:14:44ezmobius enters the room.
19:23:31Arjen_ enters the room.
19:25:06ezmobius leaves the room.
19:35:32joachimm enters the room.
19:44:37BobFunk enters the room.
19:48:19keisukef_ leaves the room.
19:52:50dbussinkdgtized: you there?
19:57:48imajes enters the room.
20:03:10cikqc enters the room.
20:09:59BobFunk leaves the room.
20:11:30botanicus leaves the room.
20:17:43octopod leaves the room.
20:24:38chris2 leaves the room.
20:46:32shame enters the room.
20:48:44nari_ enters the room.
20:50:12nari leaves the room.
20:53:41dgtizedyes
20:53:47guitsaru enters the room.
21:01:19dbussinkdgtized: i was wondering if you'd be willing to test whether my refactoring broke anything for you
21:01:33dbussinkyou seem to have the most anal compiler :P
21:01:56timo enters the room.
21:02:38dbussinkand you were wondering what all the different types are about?
21:14:43dgtizedlet me check
21:14:58dgtizedyup that compiles clean
21:15:29dgtizedit just seems we can't use native_int as a parameter for a function
21:15:35dgtizedwe have to provide a int and long
21:15:53dgtizedunless we can guarentee that only native_ints will be passed to the function
21:16:22benny enters the room.
21:17:19yroc enters the room.
21:20:15ezmobius enters the room.
21:23:25Fullmoon enters the room.
21:27:30Defilerevan: Got a question about cpp primitives and subclasses
21:27:40evanok
21:27:41evanwassup
21:27:53DefilerLet's say we have "string_new"
21:28:04Defilerand class MyString < String
21:28:40DefilerWe need to make sure that the string we create has MyString as its klass field, etc, etc.
21:28:44DefilerSo two questions..
21:29:22DefilerOK, one question.. do we have a generic way to get at the receiver of a primitive other than 'this'?
21:29:36DefilerBecause 'this' can't be used in static functions, and we have various static prims
21:31:02dbussinkdgtized: well, the reason for all the types is mainly because of FFI
21:31:03evanah ha!
21:31:13evanDefiler: I had this thought too.
21:31:25dbussinkdgtized: which has to handle all those types coming from C functions, internally only native_int is used
21:31:31DefilerMy current idea is to ask the active task what the recevier is
21:31:36Defilerbut I'm not all that sure that is the right way
21:31:38evanit doesn't know.
21:31:39dbussinkdgtized: that's why Fixnum::from only has a version for native_int
21:31:56DefilerI thought task had a 'self' accessor?
21:31:56evanDefiler: that would work, but the active context's self isn't set to the receiver of a primitive
21:32:09Defilerah
21:32:09evanyeah, but it's the self of the context that called the primitive
21:32:11Defilerbrutal
21:32:12evannot the primitive itself.
21:32:18Defilermakes sense though
21:32:31evanwe should just extend field_extract a little
21:32:46Defilerchanging 'self' inside a method, which is what the effect would be, would probably lead to fun
21:32:47evanhave it check if the 2nd argument is 'OBJECT self'
21:32:49evanif it is
21:32:55evanpass the primitive receiver in
21:33:37Defileris task->active->primitive a bad idea to add?
21:33:48evanyes.
21:33:51evanwell, what would it do?
21:34:16evantypically, adding new fields to MethodContext should be avoided
21:34:41DefilerI was imagining that it might contain information about the currently-executing primitive, if any
21:34:48Defilerbut you are right, MC has enough jobs already
21:35:01DefilerWhat with bustin' phat rhymes and all
21:35:13evanyeah, it's a tough job throwin' it down.
21:35:23jbarnetteAND keepin' it real
21:35:39DefilerRepresentin' can indeed be a burden.
21:35:55jbarnettemo money, mo problems
21:36:09DefilerOK, so field_generator is the plan?
21:36:23evanyeah
21:36:30evanyou want to tackle that?
21:36:36DefilerSure
21:36:37evanoh awit
21:36:39evanhold up.
21:36:40Defilerk
21:36:59evanI made a change to field_gen earlier today
21:37:03evanlet me commit it first
21:37:14evanso you're working against the real deal.
21:37:19DefilerSweet
21:37:33evaner.
21:37:37evanwe're talking about field_extract
21:37:38evanbtw.
21:37:44evannot sure why I was calling it field_gen
21:38:20evanalright, the shiz is in.
21:38:23CIA-20* Add ability to have custom mark logic; c785864 - Evan Phoenix
21:38:23CIA-20* Fix glue generation for static methods; 53f3ce1 - Evan Phoenix
21:38:24DefilerIt's all good. I speak evan pretty fluently these days I think
21:41:31DefilerSo, do I just want to emulate what 'pass_state' does, but for 'pass_receiver'?
21:41:45evansue
21:41:47evansure
21:41:47Defiler'punt_returner'
21:41:55evanhah
21:41:59evan'score_touchdown'
21:42:14evan'chopblock_tightend'
21:42:23DefilerOK we totally need a function with that name
21:42:29evanwhich?
21:42:33Defilerchopblock
21:42:44evanheh
21:42:51ezmobius leaves the room.
21:59:30octopod enters the room.
22:01:20ezmobius enters the room.
22:03:01wmoxam leaves the room.
22:03:52imajes leaves the room.
22:03:58AndrewO leaves the room.
22:11:59yroc leaves the room.
22:25:36pauldix leaves the room.
22:38:41headius enters the room.
22:44:23Maledictus leaves the room.
22:48:00shame leaves the room.
22:50:12shame enters the room.
22:50:18shame leaves the room.
22:51:13blakewatters leaves the room.
22:51:14Defilerevan: What kind of 'flags' are supported by // slot?
22:51:21evanflags?
22:51:34evannone?
22:51:35Defilerthe field extractor looks for a pattern after // slot
22:51:40Defilerand calls it 'flag'
22:51:57Defilerwhich it then passes to 'add_field' along with the index, name, and type
22:52:11evanoh
22:52:12evanreadonly
22:52:14evanis the old flag
22:52:16evanonly
22:52:25DefilerI don't see any usage of it. can I remove it?
22:52:29evanyou can see that in all_fields
22:52:31evanno
22:52:35evanit's supposed to be in use.
22:52:40evansomeone must have remove it
22:52:52DefilerWhat's an example slot that would have this flag on it?
22:53:16evanTuple* look_but_dont_touch; // slot readonly
22:54:11DefilerI mean in the existing VM
22:54:36evanthere are potentialy a number of them
22:54:48DefilerOK. Cool.
22:55:53DefilerDo we need a generic flag concept, or should we consider just supporting readonly directly?
22:56:11evanwell, it's not really generic
22:56:13evanas you can see
22:56:14Defileryeah
22:56:22evanthe only thing that can be detected is readonly
22:56:28evanso the code is already doing that.
22:56:30DefilerI'm just thinking that // readonly_slot would be less code
22:56:34evanno
22:56:50evanless code in field_extract, more confusing in the cpp
22:56:50Defileror even just // slot readonly explicitly in the pattern
22:56:58enebo leaves the room.
22:56:58evannah
22:57:10evando I need to pull you out of the rabit hole?
22:57:12evanrabbit
22:57:12DefilerNo
22:57:28DefilerJust wanting to make sure I understand the feature set of field_extract
22:57:42DefilerSince I get yelled at whenever I ask a question that is answered by this code. :)
23:01:02headiusevan: saw your response...ok
23:01:32evanheadius: for an array type, does it use the same header as other objects?
23:01:36evanheadius: or a more compact one?
23:01:40headiusit's a more compact one
23:01:43michalw leaves the room.
23:02:05evanok
23:02:14headiusthe only methods you can call on arrays are those that exist on Object...they're objects, but not really full Class types in themselves
23:02:14evanI play with that idea a little last night and this morning.
23:02:30evanwell
23:02:38evanthen they have some primitive operations I assume
23:02:50evanwho's usage is decided upon using static typeing
23:04:48headiusyes, primitive operations include accessing elements and length
23:05:48headiusbytecodes for each array store/load operation per component type (reference or one of the primitives) and a single bytecode for array construction
23:06:36headiusfor a VM with no primitives, obviously they could all just be reference or handle operations
23:07:21headiusit's largely because of the array bytecodes that JVM can eliminate boundschecking, unroll array element iteration loops, and so on
23:07:43evanso there are array_get_int, array_get_byte, array_get_bool, etc bytecodes?
23:08:02headiusyes
23:08:12headiusand one for object references
23:08:53headiusin-memory the primitive arrays are C + N
23:08:55headiuser
23:08:57headiusC + N * element size
23:08:59headiuswhere C is some constant header size and N is number of elements
23:09:02moofbong leaves the room.
23:09:12headiusso an array of bytes is actually byte-sized elements
23:09:39evansure
23:09:46evannormal C semantics.
23:09:55headiusbut it's worth noting that most other primitive references are 32-bit always
23:10:20evanthere isn't 64bit integer or float?
23:10:36headiusthere is, but they're not atomic 64-bit operations
23:10:56headiusso a 64-bit long field on a class needs to be synchronized if it's read/written across threads
23:11:06headiusnot an issue that comes up in practice much though
23:11:25headiusand that may not be the case on 64-bit JVMs...more an impl detail
23:11:46headiusof more import is the fact that no field reference ever takes up less than 32 bits
23:11:47evanok
23:11:57headiusbyte, short, whatever...a field is at least 32 bits always
23:12:33headiusso for example there's more int (32-bit) operations than ops for <32bit
23:12:38evanbut one byte doesn't use 32bits per byte, right?
23:12:49headiusit does except when it's in an array
23:12:57headiuseverywhere else it takes up a full 32-bit slot
23:13:01evanright, ok.
23:13:20headiusand of course the stack is uniformly 32 bit
23:13:32headiuswhich is largely why long operations aren't natively atomic
23:14:14headiusat any rate, array types are a special class of object in memory
23:15:54headiussome of these articles might be interesting to you
23:15:55headiushttp://wikis.sun.com/display/HotSpotInternals/Home
23:16:41evank
23:16:49bremac2 enters the room.
23:16:51headiushotspot in general would probably be interesting to you since it's largely modeled after smalltalk VMs and the core is C++
23:18:06evanheadius: whats present in an empty JVM?
23:18:33headiuswell, that's a good question
23:18:53headiusa mix of a lot of C++, ASM, and Java code
23:18:55headiusprobably mostly Java code
23:19:01evani mean
23:19:04evanif you boot up the jvm
23:19:11evanwhat stuff is already loaded in?
23:19:17evanthe java core library?
23:19:42headiusnot the entire library...but all classes (Java and C++) needed for the basic bootstrapping
23:19:45binary42 leaves the room.
23:20:03BobFunk enters the room.
23:20:04headiuswhich includes some filesystem-related classes for loading, classloaders, bytecode verifiers
23:20:25headiusa bytecode interpreter, memory manager, maybe a JIT
23:20:44evanbut most of that isn't exposed in java-land
23:20:55evanthats all stuff loaded under-the-hood
23:21:00headiusvery little of it is exposed directly, a lot of it never exposed
23:21:25headiusfor userspace, JVM only presents the set of core classes in java.lang on boot
23:21:56headiusfile:///Users/headius/java6-docs/api/java/lang/package-summary.html
23:21:57headiuser
23:21:58headiusoops
23:22:10headiushttp://java.sun.com/j2se/1.5.0/docs/api/java/lang/package-summary.html
23:23:04headiusthe smallest JVMs might *only* expose that set of classes
23:25:27headiuson my system a simple Java class that starts up and immediately sleeps takes about 10MB of memory
23:25:48evanok
23:26:11headiusa script that sleeps in JRuby starts up around 20MB
23:28:11evangotcha
23:28:45shame enters the room.
23:30:47octopod leaves the room.
23:31:36edwardam enters the room.
23:33:46c0sin leaves the room.
23:34:14Arjen_ leaves the room.
23:36:35BobFunk leaves the room.
23:36:36codebrulee enters the room.
23:38:11BobFunk enters the room.
23:45:44Fullmoon leaves the room.
23:46:44Fullmoon enters the room.
23:47:03ch0wda leaves the room.
23:47:42cyndis leaves the room.
23:49:07c0sin enters the room.
23:49:54c0sin leaves the room.
23:56:36yipstar leaves the room.
23:58:29cyndis enters the room.