[02:10] <psusi> cjwatson, can I pick your brain for a second about the 'p' partition separator issue for dmraid device paths?
[02:10] <cjwatson> no point picking my brain at 2am
[02:10] <ohsix> hi, it is _very_ hard to profile things without a frame pointer on x86_64, is there a way someone could be convinced to put actual binaries with them enabled in the dbgsym packages?
[02:11] <cjwatson> there's not much of it to pick
[02:12] <psusi> hehe... ok... maybe I'll catch you tomorrow ;)
[02:12] <cjwatson> you always seem to try to find me on IRC at this kind of time
[02:13] <cjwatson> it's not really very doomed to success - even if I'm here I'm only doing mindless things :)
[02:13] <psusi> hehe... I'll look for you in the morning ;)
[02:14] <psusi> was out of the house most of today... friend's had a baby
[02:14] <cjwatson> congratulations (by proxy)
[02:14] <psusi> hehe
[02:14] <ohsix> is there an x86_64 "debug team"? it makes apport retracing pretty ugly too
[02:15] <ohsix> right now i have to build everything myself or use 32bit, which isn't my daily driver
[02:16] <psusi> why is it any harder on x86_64?  I thought the debug symbols had enough information to reconstruct the stack trace without frame pointers?
[02:16] <cjwatson> dbgsym packages are just stripped symbols, not a separate build pass
[02:16] <cjwatson> they can't use compiler options that the original binaries didn't use
[02:17] <psusi> for that matter, why is -fomit-frame-pointer even used on x86-64?  makes sense with x86 since it has so few registers to begin with, but x86-64 has plenty.. how much difference does one more really make?
[02:17] <cjwatson> I'm not aware of it being the default; some package must be turning it on
[02:18] <cjwatson>      `-O' also turns on `-fomit-frame-pointer' on machines where doing
[02:18] <cjwatson>      so does not interfere with debugging.
[02:18] <ohsix> psusi: it's part of the calling convention
[02:18] <cjwatson> unless that's the case on amd64, I don't know
[02:18] <cjwatson> but if it is, there should be no problem by definition
[02:18] <psusi> ohsix, eh?
[02:19] <ohsix> ok here it is in another form: can someone be persuaded to enable it unconditionally for all packages
[02:19] <ohsix> psusi: the x86_64 calling convention has something to say about frame pointers
[02:19] <cjwatson> I think we need a more specific report
[02:19] <psusi> ohsix, you mean it doesn't have one at all?
[02:19] <cjwatson> e.g. which packages have this problem?
[02:21] <ohsix> cjwatson: all of X and its peripheral packages, pixman, cairo, transmission, rhythmbox (but this is just for now, i've tried profiling/debugging other packages to the same end)
[02:22] <psusi> ohsix, it looks like it has ebp to me... so it should be used
[02:22] <cjwatson> the x86-64 ABI does not specify whether a frame pointer is used or not.
[02:22] <ohsix> ehhhh
[02:22] <psusi> that's what I thought...
[02:22] <psusi> just like x86
[02:22] <cjwatson> "%rbp  callee-saved register; optionally used as frame pointer"
[02:22] <psusi> the register is there and it is suggested you use it, but you don't have to
[02:22] <ohsix> ok
[02:22] <cjwatson> http://www.x86-64.org/documentation/abi.pdf
[02:23] <ohsix> right, thanks for looking it up; some windows brain damage might still be muddying my thoughts on the subject
[02:23] <psusi> hehe
[02:24] <ohsix> so how to get me some -fno-omit-frame-pointer, in a manner that supersedes -On
[02:24] <psusi> I'm still curious though why it is any more annoying on 64 bit than 32?  I thought that on 32 bit without frame pointers, you just couldn't get a back trace without debug syms, but with them you could?  why is that any different for 64 bit?
[02:25] <cjwatson> looks like it's the default on x86-64, which implies (from the gcc documentation) that it is possible to do stack frame analysis without a frame pointer on x86-64
[02:25] <cjwatson> so I think you need a better way to drive gdb or whatever, not -fno-omit-frame-pointer
[02:25] <ohsix> sampling profilers need the frame pointer to figure out the calling sitel and it can unwind with them in each sample cheaply as well
[02:26] <ohsix> well, it's sysprof, perf, oprofile
[02:26] <cjwatson> if you want to build with -fno-omit-frame-pointer, you'll need to rebuild stuff yourself
[02:26] <cjwatson> we're not going to make an Ubuntu-specific change to diverge from the general GCC world's defaults on this
[02:27] <ohsix> if that were the case why don't up to date tools work at all? like, none of them
[02:27] <cjwatson> "if that were the case"> which statement of mine are you casting doubt upon?
[02:27] <ohsix> you figure it might be one or two that work without frame pointers but with the "extra" undefined steps to the same end, but none of them do
[02:27] <psusi> profiling is usually the sort of thing a developer does, not an end user, so you are expected to just build with the frame pointer I think...
[02:27] <cjwatson> I've not noticed particular problems with gdb
[02:27] <ohsix> the implication by gcc documentation
[02:28] <cjwatson> debugging != profiling
[02:28] <ohsix> heh
[02:28] <cjwatson> http://gcc.gnu.org/ml/gcc-patches/2010-08/msg00300.html and thread is related
[02:28] <ohsix> looking into why the packages are doing something in situ is debugging, and yo generally do it with a profiler
[02:29] <cjwatson> I agree with psusi.  rebuild things locally if you need additional profiling facilities.
[02:29] <ohsix> i just don't have _hours_ to find trivial problems that i want to report
[02:29] <psusi> hrm... yep, looks like -O2 definitely does turn off frame pointers...
[02:30] <ohsix> rebuilding to get the information that you'd get with a frame pointer, for the stuff i'm looking at, rebuilds half the system
[02:30] <cjwatson> sorry
[02:30] <cjwatson> looks like the frame-pointer decision was taken at a level well above Ubuntu in the toolchain world, and I don't think it would be appropriate for us to undo it
[02:31] <psusi> hrm... interesting.. I just compiled int main() { int x = foo(); return x; } with -O2 and it is only 2 instructions: xor %eax, %eax, and jmpq <foo>
[02:31] <ohsix> it's not undoing it heh
[02:31] <ohsix> it's "can you do this in situ" or not
[02:32] <psusi> if the profiler requires frame pointers, then no, you will have to rebuild locally to get them
[02:32] <ohsix> rebuild the entire system
[02:32] <psusi> no, just what you are trying to profile
[02:32] <cjwatson> you can't add frame pointers to all the dbgsym packages without undoing the toolchain decision for the distribution in general
[02:32] <ohsix> i'm just talking about the magnitude of the work in order to look at trivial things
[02:33] <psusi> getting detailed timing measurements on a function by function basis is hardly looking at trivial things ;)
[02:33] <ohsix> psusi: the 3 applicatioins that are involved need like 50 packages rebuilt
[02:34] <cjwatson> only if you need to profile the entire stack, which isn't usually the case
[02:34] <ohsix> i understand your position but i really can't belive you don't accept that it would be nice for fixing things if it was the other way around
[02:34] <psusi> it would be nice, but it's not going to happen ;)
[02:34] <ohsix> need the X server, libdrm libdrm-intel cairo pixman libc6 gtk some gtk engines, transmission and some of its deps, and rhythmbox
[02:35] <cjwatson> there are many things I accept, but they generally tend to involve things where it's kind of in time to fix them
[02:35] <cjwatson> in this case it is far too late; the discussion should've been had way back
[02:35] <psusi> though I am curious why gcc decided to turn on omit-frame-pointer with -O2 on amd64... it doesn't seem like it would add much so I would have left it off
[02:35] <cjwatson> psusi: the people who did the x86-64 port thought it was a good idea
[02:35] <cjwatson> not so much "gcc decided"
[02:36] <ohsix> cjwatson: i'll look into this some more; i've already read the old threads some time ago, but for a distro the cost in debugability is probably too high for any point made in them
[02:36] <cjwatson> ohsix: I have to say, this is never something I have run into
[02:36] <cjwatson> so I don't see it as a major cost
[02:37] <ohsix> well you're not me, i try and triage every little bug i find with performance and there are a lot of them, and i can't often get satisfactory answers without days of work for even the most trivial among them
[02:37] <cjwatson> you're trying to make statements about the cost to the distribution for debuggability in general
[02:37] <broder> i'm still confused about not having a frame pointer is a problem - gdb can give me a backtrace for anything if i have the debugging symbols
[02:38] <cjwatson> and I'm saying that I don't think the cost is that general
[02:38] <ohsix> broder: sampling profilers sample ip and the frame pointer to unwind later
[02:38] <ohsix> cjwatson: it makes perf useless
[02:38] <cjwatson> and that people doing this kind of sweeping performance work are likely to need to build substitute versions of packages anyway
[02:38] <broder> so why couldn't they just capture the stack insted
[02:38] <broder> ?
[02:38] <psusi> jesus christ, how the hell did gcc optimize this that much?  this function doens't even have a stack frame!
[02:39] <cjwatson> unless you're doing performance analysis but not changing anything, which seems less useful
[02:39] <ohsix> broder: 1000, 10000 times a second, even if they could, how would you read the traces?
[02:39] <cjwatson> set up an autobuilder to do the builds for you, it wouldn't take long
[02:39] <micahg> !ohmy > psusi
[02:40] <broder> ohsix: you can post-process for a stack trace easily enough if that's what you want
[02:40] <ohsix> psusi: leaf functions are beholden to their calling sites, and if they're idempotent they can be replaced entirely
[02:40] <ohsix> broder: if you could, why doesn't perf, sysprof, oprofile or the other profilers do it?
[02:40] <broder> presumably because nobody's implemented it yet?
[02:41] <ohsix> broder: they need point in time samples, thats how they work
[02:41] <broder> right. they need point in time samples of the stack trace. so take point in time samples of the stack, and backsolve
[02:42] <ohsix> you know every monotonic time x and the information it yields is statistical
[02:42] <cjwatson> in any case, this discussion should be had with the gcc x86 backend maintainers and the maintainers of the profiling tools in question.  Ubuntu's too narrow a forum.
[02:42] <broder> ohsix: yes, i understand how statistical profiling works. you're still not explaining to me why it's not possible to do that after the fact if you can extrapolate a stack trace, which debuggers experimentally can
[02:42] <ohsix> cjwatson: i don't propose changing the toolchain, that'd actually be pretty silly, it's just desirable for the stuff you actually run to let you introspect a bit
[02:43] <psusi> wow... well now I understand why amd decided that the caller should clean up the stack... that kind of upset me at first since caller cleanup usually generates smaller code.. I didn't think caller cleanup could generate both smaller and faster code sometimes
[02:43] <cjwatson> the stuff you actually run != the stuff somebody else actually runs
[02:43] <ohsix> broder: if it was possible i'm pretty sure you could pick a maintained profiler today and get useful output with it
[02:43] <cjwatson> you can't make a coherent argument for which packages should have this treatment.  this is why it's a toolchain decision
[02:44] <ohsix> cjwatson: i guess, but not on anything else than ubuntu
[02:44] <ohsix> it's a distro decision, they either care or don't
[02:44] <cjwatson> it would be unhealthy for Ubuntu to diverge from the rest of the x86-64 wowrld here
[02:44] <cjwatson> *world
[02:45] <cjwatson> while in principle distros can change anything, I don't agree that this should generally be a distro decision
[02:45] <ohsix> the only argument i could make, which i haven't; is that i find i need to do this very often, and its with lots of packages
[02:46] <ohsix> so you don't see the value in not having to rebuild half your system locally to do something that should be trivial?
[02:46] <psusi> ohsix, why do you frequently need detailed timing measurements for every single function that a large, complex program calls?  usually you only profile the functions in the program, not every library it calls as well
[02:47] <ohsix> psusi: while its not every, it is still a _lot_
[02:47] <ohsix> psusi: case in point 2 applications are making a third go nuts, and theres little indication which part it is
[02:48] <cjwatson> ohsix: I see the value, but it doesn't override other considerations
[02:48] <ohsix> are there others?
[02:48] <cjwatson> there's also value in having our general optimisation strategy be at least vaguely similar to other distributions and to upstream!
[02:49] <ohsix> sure
[02:49] <ohsix> theres value in everything going upstream
[02:49] <cjwatson> http://old.nabble.com/x86_64-callgraph-support-td21947441.html is relevant
[02:49] <cjwatson> (sorry, nabble is annoying but I didn't find a better URL quickly)
[02:49] <cjwatson> points out that oprofile should be fixed to use dwarf2 unwind information
[02:50] <ohsix> hm
[02:50] <cjwatson> and Andi Kleen knows what he's talking about for x86-64
[02:51] <ohsix> what about perf? it has it already
[02:51] <cjwatson> fix that, and now the profiler works better for everyone
[02:51] <psusi> cjwatson, since your brain seems to still be working pretty well, I'm going to throw the 'p' problem at you and see if you have any thoughts on it tonight, or can sleep on it.  to sum up: dmraid and parted now always add 'p' before the partition number when figuring the device name for the partition.  gparted and kpartx only add the 'p' if the previous char is a digit.  They need to agree, so which method is right?
[02:52] <cjwatson> I don't have a clue, I've never been able to keep this straight :)
[02:52] <psusi> hehe
[02:52] <ohsix> brb
[02:52] <cjwatson> I would tend to trust the lower-level tools, if that's the upstream behaviour
[02:52] <psusi> I know I need to patch something to fix this for natty, but I'm having trouble deciding which
[02:53] <cjwatson> does the kernel code have an opinion on this?
[02:53] <psusi> which is lower?  dmraid and parted or kpartx?
[02:53] <psusi> the kernel just does what it is told... it doesn't care what you name it
[02:53] <cjwatson> hm, I would probably have said dmraid but I suppose I'm not certain
[02:53] <cjwatson> the kernel sometimes has defaults for device names
[02:53] <psusi> but someone said that other devices the kernel used ot have to name that could end in a digit it added the 'p' only if it already ended in a digit
[02:54] <ohsix> cjwatson: since you talked me down a bit i'm gonna do more due diligence wrt. the tools i've been trying to use
[02:54] <cjwatson> perf: http://lwn.net/Articles/409797/
[02:54] <psusi> that makes sense to me and to the gparted maintainer... so I'm tempted to patch dmraid and parted to do that
[02:54] <cjwatson> psusi: it's certainly more aesthetically pleasing the kpartx way
[02:55] <ohsix> cjwatson: yar i saw it in the git log for the kernel
[02:55] <psusi> I agree
[02:55] <cjwatson> I'm a bit worried about the continuing device name transitions though
[02:55] <cjwatson> s/continuing/repeated/
[02:55] <psusi> and causes less disturbance than always adding it...
[02:55] <ohsix> ah, the clincher: - only support for x86-32. I need to split some arch specific code from
[02:55] <ohsix>   generic and add at least x86-64 support.
[02:55] <cjwatson> ohsix: right, but no suggestion that it isn't possible
[02:55] <ohsix> well now i'm just angry :D cuz i have to rebuild anyways
[02:56] <cjwatson> psusi: who was it that made a comment on parted-devel about several different bits of software having been carefully lined up upstream to do the right thing here?
[02:56] <cjwatson> was it one of the LVM guys or something?
[02:57] <ohsix> the real problem is the rhythmbox guys aren't taking my traces and the proof i've offered in many forms as evidence thatit's doing what i say it's doing; and i'd like to get it fixed
[02:57] <ohsix> i think its the theme engine, transmission does the same thing but to a different degree; transmission just really pegs the x server doing it
[02:58] <cjwatson> if I were debugging that sort of thing I think I would work at the X protocol level rather than at the C call graph level
[02:58] <cjwatson> but perhaps I shouldn't armchair-quarterback you
[02:59] <ohsix> my laptop is my daily driver & spending a dayor two building stuff is not my idea of fun, not to mention i don't have the bandwidth to commit to get the patches
[02:59] <ohsix> i tried xtrace, it shows the operations but not why it takes so long in the server
[02:59] <ohsix> perf would show traces all the way through if it worked
[03:00] <cjwatson> psusi: you seem to be already having the conversation upstream, anyway, and there've been quite a few knowledgeable responses on parted-devel etc. already
[03:00] <ohsix> plus the fix wouldn't come from trace info from X, you'd sooner look to pixman/cairo, then the theme poking at it
[03:01] <ohsix> that there are lots of probably useless messages at the connection level should be moot; cuz theres probably fixes in that area needed inboth the video driver and the theme engine
[03:02] <ohsix> i might just have to throw my hands up until circumstances are different, fetching/building so much stuff is a blocker
[03:02] <cjwatson> psusi: Hannes' "linux scheme since the dawn of time" is the more aesthetically pleasing one, which is good I guess
[03:02] <cjwatson> ohsix: sounds like you have great motivation to improve perf :)
[03:03] <ohsix> cjwatson: i don't know enough to judge if the effort is worth it; also the aforementioned "evidence", perf isn't good enough
[03:04] <ohsix> oh, i do have a good suggestion for apport information to gather
[03:04] <ohsix> get the theme engine name!
[03:05] <ohsix> it has a ridiculous impact on things
[03:05] <cjwatson> the apport maintainer is not currently logged in hre - if you want to suggest apport changes, you'll need to file a bug
[03:06] <cjwatson> *here
[03:06] <cjwatson> sounds like a reasonable thing to collect
[03:06] <ohsix> first bug i'll file is against rhythmbox :]
[03:09] <ohsix> so how easy is it to rebuild everything without making a mess for a subset of the packages? i messed with apt-build to do it on a handful of packages, but that seems generally untenable
[03:11] <cjwatson> quite a bit of work's gone into sbuild et al; I'd use that if I needed this kind of thing
[03:13] <ohsix> from what i do know i'd want to set the origin so it'd be easy to downgrade when i'm done, and at best provide just top level package names & have the deps handle themselves like apt does
[03:15] <psusi> cjwatson, if you mean a few days ago, that would be me ;)
[03:17] <psusi> cjwatson, I'm kind of disappointed at how few responses there have been though, especially from the redhat guys that maintain dmraid... I think the right thing to do is patch dmraid and parted, but I'd like some upstream approval
[03:18] <ohsix> o noes skew
[03:19] <ohsix> another question: is there a warning displayed when partman is having its way with the disk in ubiquity
[03:19] <cjwatson> I don't understand the question
[03:20] <ohsix> resizing or rather, interrupting a partition resize is something that's bad to do
[03:20] <cjwatson> normally resizers are actually very careful to ensure that interruptions are safe
[03:21] <cjwatson> they have to be in case of power loss
[03:21] <ohsix> i haven't seen the installer since 10.10 & i haven't resized since ever, but someone on the support channel interrupted it during a resize and lost his disks
[03:21] <cjwatson> then that should be a bug on the resize program, not patched around by UI in the installer
[03:22] <ohsix> even if the resizer is perfect there are sill operations that aren't atomic and will trash the drive
[03:22] <ohsix> its just bad luck for it to happen, but it's a real risk
[03:22] <psusi> oh nevermind... I see some responses now.. damn redhat mailing lists mangle reply-to header.. I didn't get the replies directly
[03:22] <cjwatson> such as?
[03:23] <ohsix> heh
[03:23] <ohsix> filesystems have metadata that aren't in sync in the same manner as they would be if they're mounted in the resizer
[03:24] <ohsix> stopping in the middle of messing with the mft on ntfs can lose all of the directory entries on ntfs
[03:24] <cjwatson> ah, ok, an abort in resize2fs when moving the inode table would be a problem, true
[03:24] <cjwatson> I hate having to resort to UI warnings, but I suppose it might be necessary here
[03:24] <cjwatson> file a bug then
[03:24] <ohsix> just a general question anyways, i know a warning would look bad and 99.99% of the time supefluous
[03:25] <ohsix> alright
[03:25] <cjwatson> ideally we would determine when the resizer is in the dangerous bit
[03:25] <cjwatson> that may not be feasible
[03:25] <psusi> wait, how is it not interruption safe?  resize2fs only adds or removes inode tables, not moves them afaik
[03:25] <ohsix> i'd just hate for my grandma to lose photos or anything on the computer, even though its supposed to be a safe-ish operation
[03:26] <ohsix> psusi: power interruptions can come after the OS has asked the disk to flush something, but before it has
[03:26] <ohsix> thats not "
[03:26] <ohsix> er, that's not
[03:26] <ohsix> "vghfy89uhcgfyug
[03:26] <ohsix> not the problem but it is the bottom line, sorry about that
[03:26] <cjwatson> psusi: see comment in e2fsprogs/resize/resize2fs.c above move_itables
[03:26] <ohsix> key hitting enter with my pinky :]
[03:27] <cjwatson> search for "This is scary"
[03:27] <ohsix> cjwatson: i dunno if the documentation is out there to find what operations are unsafe in reality on ntfs, and that'd be the big one
[03:28] <cjwatson> ohsix: in some modes, ntfsresize emits a warning when it's about to start with the unsafe operation
[03:28] <cjwatson> s
[03:28] <ohsix> a power removal warning would suffice
[03:28] <cjwatson> search for resize_warning_msg in the source
[03:28] <ohsix> cjwatson: ah cool
[03:28] <psusi> I thought that everyone understands that resizing a partition is inherently a dangerous operation and bad things happen if the power goes out in the middle, but that resize2fs tried to make sure it would be ok, and generally did a fairly good job of it
[03:29] <ohsix> i will; you've giveb me a lot to do tonight
[03:29] <ohsix> psusi: my mom doesn't, i do
[03:29] <cjwatson> psusi: the bulk of the resize (copying data around) is safe, but there's twiddling at the end that isn't
[03:29] <psusi> ARGH!@$
[03:29] <ohsix> psusi: i figure ubiquity is more for her than me :]
[03:29] <psusi> that single pixel border can't resize thing is really starting to get on my nerves
[03:29] <cjwatson> ohsix: the same problem would exist in d-i
[03:30] <ohsix> cjwatson: sure, but i didn't help her put debian on the netbook i gave her
[03:30] <cjwatson> (d-i's used in Ubuntu too)
[03:33] <psusi> cjwatson, by move inode table, this code means evict inodes from the tables that are going away right?  shouldn't they be copied to the destination, then the directories updated with the new inode number?  so if interrupted then at worst you have the inode duplicated and either fsck should deal with that, or resize2fs should be able to resume?
[03:34] <cjwatson> the code comment says it's moving things in place
[03:34] <cjwatson> probably best to read the code if you have questions about it
[03:34] <cjwatson> I'm willing to take it at its own word that it's dangerous
[03:34] <ohsix> ultimately it can't be done perfectly safely like a filesystem can make some failure assurances in how it works
[03:35] <cjwatson> the reason I don't want a warning throughout resizing is that the time-consuming part of resizing is typically implemented safely
[03:35] <ohsix> what a real fs driver can do though, is have the inode in core while its messing with the file
[03:35] <ohsix> cjwatson: right
[03:36] <ohsix> something that just says anything about removing power should suffice
[03:36] <psusi> there's no reason it CANT be done safely... you might have to do some more work that will take longer, but...
[03:36] <ohsix> psusi: you need some things to be atomic or restartable to be completely safe, you can't get that
[03:36] <cjwatson> resize2fs is not notorious for emphasising performance over safety
[03:36] <psusi> ohsix, sure you can
[03:37] <cjwatson> if you can make its phase 5 safe, I'm sure they'd take a patch
[03:37] <ohsix> if resize2fs put shadow copies in the new place then updated metadata it could be safe_r_
[03:37] <psusi> that's basically what I just said I thought it did
[03:37] <ohsix> but like i said, the lowest common denominator is power removal
[03:37] <ohsix> right
[03:38] <ohsix> for smaller structures it might be fine
[03:39] <ohsix> the mft on ntfs is a large part of the drive, you could fragment it in the process to make it safer, but i'd have to see what it actually does
[03:39] <ohsix> i've never had an mft split on any resizes i've donr
[03:39] <psusi> as long as the mft doesn't have extents in the region you are truncating, you should not need to mess with it much when resizing
[03:40] <ohsix> not with gparted anyways
[03:40] <ohsix> right, but its supposed to be a percentage of the drive, the volume size & the mft is set as a ratio to support a certain number of files/directories
[03:41] <psusi> that's just a mkfs default thing... don't have to maintain it when resizing
[03:41] <psusi> it gets enlarged as needed
[03:41] <ohsix> if you don't touch the mft you might not have any space for new files afer a resize
[03:42] <ohsix> its moot though, if that's not what it does, i'll have to look
[03:42] <psusi> also iirc, there was a registry key or something you could tweak to change that default size so you could decrease it to leave more free space or reserve more for many files... basically like when you set the inode ratio with mke2fs, only the mft can grow dynamically
[03:43] <ohsix> in fact i've got storage available i could just try it out
[03:43] <ohsix> psusi: i know, but the thing is it takes 20% of the disk or more, depending on how many files are on it, my point was that if you hit the mft you could have taken all the space for actual files, and to grow the mft
[03:46] <psusi> OHHH!  when enlarging a fs, the bg descriptor table grows larger, so for block groups that contain a copy, that will shove the inode table to the right
[03:46] <ohsix> split mft is another problem
[03:47] <ohsix> it by chance can end up in the end, and need to be moved; iirc ntfsresize takes this into account wrt. what it is able to resize, and wont let you shrink it lower than the end of the mft
[03:47] <psusi> ohsix, yea, that's what I thought
[03:47] <ohsix> unless something is restartable theres always a power danger
[03:48] <ohsix> it'd be awesome if they were though :D i see no reason why they couldn't, aside from lots of extra io for bookeeping and needing storage for it somewhere
[03:48] <psusi> I've been giving some thought to making e2defrag restartable, but it would make it so much slower and more complicated...
[03:48] <ohsix> can't you just go by inode, then a restart is start at x? :D
[03:49] <psusi> it builds an entire new drive map in memory first, then starts relocating blocks from the old locations ot the new locations....
[03:49] <ohsix> xfs goes by AG then inode and it's just 2 integers to restart, but it's cheap to start again as well
[03:49] <ohsix> ah
[03:50] <ohsix> maybe you can whip up a magic hash to get rid of the map
[03:50] <psusi> that's why it's so fast ;)
[03:50] <psusi> if you have enough memory no block gets written more than once
[03:50] <psusi> and almost all of the IO is in large blocks... minimum seeking
[03:51] <ohsix> right
[03:51] <psusi> if you have enough memory to hold it all, it can actually manage to rewrite the whole fs in one big read and one big write
[03:51] <ohsix> that's the best way to do it if you have some guarantees about interruptions
[03:52] <ohsix> copying and leaving metadata to be updated until the last moment then marking the old area empty takes extra copies
[03:53] <psusi> yea... and extra seeks... right now it reads all of the inodes, updates them, writes them back, then starts relocating blocks
[04:02] <psusi> err, wait.. that's what the resize inode is for..
[04:02] <psusi> is that only needed for online resize?  can resize2fs still work offline without the resize inode?
[04:03] <ohsix> no idea
[04:04] <cjwatson> yes
[04:05] <psusi> ok, that makes sense then.. yea, phase 5 it says only runs if neccesary... not needed if you have a resize inode it sounds like
[04:06] <psusi> whoa... copyright ted and powerquest inc?... interesting...
[04:06] <ohsix> cjwatson: http://lwn.net/Articles/380582/
[04:06] <ohsix> broder: you might like that as well
[04:12]  * psusi wonders what ever happened to that project to make a Linux equivalent of WinIce... that was one slick debugger
[04:12] <SchizoBunny|home> how do you get it to do that ^^
[04:13] <psusi> ?
[04:13] <ohsix> SchizoBunny|home: prefix your message with /me
[04:13] <SchizoBunny|home> ok thank you
[04:14] <psusi> ohh, hehe
[04:15] <ohsix> anyways, with perf and sysprof the idea is to profile from the app all the way through the kernel, or between stuff in the kernel, the time it samples, how often it samples, and what it samples are hard constraints :[
[04:17] <ohsix> perf is _great_ too, it's a shame
[04:22] <psusi> someone posted an interesting problem this week with gdb on askubuntu.com... if you tell gdb to print strlen(something) you get garbage results... if you assign strlen to another pointer and use that to call it instead in the gdb expression, it works...
[04:24] <ohsix> different calling convention from the gdb stack frame setup to make the call from the sound of it
[04:32] <ohsix> apparently systemtap works, but only with -fasynchronus-unwind-tables; how can i find out of that's set on ubuntu
[04:33] <ohsix> http://gcc.gnu.org/ml/gcc-patches/2010-08/msg00337.html uhuhuh
[04:37] <ohsix> http://gcc.gnu.org/ml/gcc-patches/2010-08/msg00342.html <- by who indeed
[04:37]  * ohsix keeps looking
[04:37] <ohsix> it looks like h.j. lu just did it by fiat
[04:41] <ohsix> cjwatson: apparently the 386 abi says the same thing about the frame pointer register and its optionalness, people writing unwinders just used it if it was there; and that didn't make it to x86_64
[04:41] <ohsix> http://gcc.gnu.org/ml/gcc-patches/2010-08/msg00223.html
[04:43] <ohsix> http://gcc.gnu.org/ml/gcc-patches/2010-08/msg00354.html google engineers uncondtionally enable it on x86_64
[04:51] <psusi> ohsix, from that mail it sounds like it's been the default on x86 for some time too and it suffers the same problem.. they are saying that profilers just need fixed to deal with not having a frame pointer
[04:51] <ohsix> nah it was a proposal to enable it on x86
[04:52] <ohsix> sampling profilers that work in the kernel aren't going to be fixed for that
[04:52] <psusi> umm... I read it as a proposal to enable it on -64 and the response was that x86 has been doing it for a while and not had complaints?
[04:52] <ohsix> exactly the opposite
[04:52] <psusi> and that if you fix the profiler for -64, x86 would benefit as well
[04:52] <ohsix> yes
[04:53] <ohsix> because _64 already has the proposed change
[04:53] <ohsix> which is unconditional -fomit-frame-pointer
[04:53] <psusi> >>> Can we find if oprofile works with -fomit-frame-pointer on 32bit Linux/x86.
[04:53] <psusi> >> It doesn't for user space. The problem is that you would need
[04:53] <psusi> x86 already had it enabled
[04:53] <ohsix> apparently async unwind tables are enabled on x86_64 by default too
[04:54] <ohsix> psusi: that refers to oprofile, not gcc; it's a gcc list, the posts are about enabling -fomit-frame-pointer for x86
[04:55] <psusi> ohh, I see now
[04:55] <psusi> I was going to say, I thought that if you wanted -fomit-frame-pointer you used to have to explicitly enable it
[04:56] <psusi> at least for -O2... -O3 turned it on iirc
[04:56] <ohsix> it was discussed in 2004 as well http://gcc.gnu.org/ml/gcc-patches/2004-08/msg01033.html
[04:58] <ohsix> unfortunately there doesn't appear to be much discussion other than gdb working with dwarf info; gdb has an opportune time to read such things indeed ;]
[05:04] <ohsix> http://gcc.gnu.org/ml/gcc-patches/2004-08/msg01124.html holy hyperbole batman
[05:04] <ohsix> poor guy
[10:37] <ari-tczew> ttx: ping
[14:45] <gaurav_pawaskar> Hi guys, anybody knows algorithm to convert UTF-16 to UTF-8?????
[14:49] <artfwo> in python, I'd just call something like unicode(a, 'utf-16').encode('utf-8')
[14:49] <gaurav_pawaskar> anything in c or c++..
[14:52] <artfwo> gaurav_pawaskar, there are quite a few libraries for unicode conversion, like libicu
[14:53] <artfwo> you might also want to use something like http://utfcpp.sourceforge.net/ for a lightweight solution
[14:55] <gaurav_pawaskar> thank you artfwo...
[14:57] <penguin42> gaurav_pawaskar: I'm not sure, but iconv might be able to do it - man 3 iconv
[16:16] <Turl> hi all
[16:17] <Turl> can someone take a look at https://bugs.launchpad.net/ubuntu/+source/libva/+bug/595661 ?
[16:17] <Turl> it would be great if libva could be synced from debian
[16:23] <lamont> ScottK: https://launchpad.net/~lamont/+archive/ppa should have 2.8.0-0.1 once it finishes cranking through the process
[16:24] <lamont> ScottK: it passed my smoketest, but it really needs a more thorough looksee before I'm comfortable uploading it, and that won't happen today while I'm sleepy...  care to take a gander?
[16:24] <lamont> and actually, that's 2.8.0-0.1~lucid1
[16:32] <debfx> Turl: libva sync has already been requested: bug #721978
[16:33] <Turl> debfx: nice, let's hope it makes it in time then
[18:23] <Otacon22> humm.. I would like to know why the indicator-applet-session is taking 468MB of ram on mu ubuntu 10.04
[18:23] <Otacon22> *my
[18:24] <ohsix> Otacon22: is that what smem says?
[18:25] <Otacon22> smem?
[18:25] <ohsix> Otacon22: apt-get install smem
[18:25] <Otacon22> ok wait
[18:25] <Otacon22> in the meanwhile
[18:25] <Otacon22> USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
[18:25] <Otacon22> otacon22 22433  0.0  6.0 829112 492468 ?       Sl   Feb06  17:23 /usr/lib/indicator-applet/indicator-applet-session --oaf-activate-iid=OAFIID:GNOME_FastUserSwitchApplet_Factory --oaf-ior-fd=32
[18:25] <Otacon22> and i have 8 GB of ram.
[18:26] <Otacon22> otacon22@PhoenixDesktop:~$ smem | grep indicator-applet
[18:26] <Otacon22> 22434 otacon22 /usr/lib/indicator-applet/i     1132    27228    27629    35312
[18:26] <Otacon22> 22433 otacon22 /usr/lib/indicator-applet/i    14852   484856   485257   492504
[18:26] <Otacon22> The second one should be the right one
[18:27] <ohsix> hm odd
[18:28] <ohsix> can you post the output of /proc/22433/smaps to a pastebin
[18:28] <Otacon22> sure
[18:29] <Otacon22> http://pastebin.com/X0yNzxcB
[18:31] <ohsix> nearly 500mb heap heh, that's probably a bug, is there something you can do to make it consume a bit more ram each time you do it?
[18:31] <Otacon22> I don't know, i'm looking
[18:34] <Otacon22> I'm looking the strace in real time
[18:35] <Otacon22> Humm, nothing interesting
[18:35] <Otacon22> What could i do to investigate more about it?
[18:35] <ohsix> no idea, do you even use fast user switching?
[18:36] <Otacon22> never
[18:36] <Otacon22> i just lock the screen
[18:36] <ohsix> theres some stuff on dbus exposed by it but i don't exactly know what, something could be using that
[18:37] <ohsix> it's only using 5 megs here
[18:37] <Otacon22> but i use to keep the pc on for long time, and it seems to happen after long time
[18:37] <Otacon22> otacon22@PhoenixDesktop:~$ uptime
[18:37] <Otacon22>  19:38:41 up 16 days,  3:45, 25 users,  load average: 0.83, 0.88, 0.77
[18:39] <ohsix> 25 users?
[18:39] <ohsix> terminals right
[18:39] <ohsix> you're using maverick right, and just regular gnome?
[18:40] <Otacon22> no, 10.04 lts
[18:40] <Otacon22> yes, regular gnome, standard theme
[18:42] <ohsix> whatever it is, for only being 16 days it's happening pretty often, or it's a huge leak, dbus-monitor can show what might be invoking the indicator applet; and if it's not there i can't say much about what's left to look at :\
[18:44] <Otacon22> signal sender=:1.72 -> dest=(null destination) serial=484535 path=/org/ayatana/indicator/session/menu; interface=org.ayatana.dbusmenu; member=ItemPropertyUpdated
[18:44] <Otacon22>    int32 19
[18:44] <Otacon22>    string "restart-label"
[18:44] <Otacon22>    variant       string "Riavvia..."
[18:44] <Otacon22> there are a lot of this
[18:44] <Otacon22> "riavvia" is italian and means reboot
[18:45] <ohsix> ok
[18:46] <ohsix> install d-feet, you can look at :1.72 and see what binary it is coming from
[18:46] <Otacon22> (the ram used by the indicator is growing up)
[18:47] <ohsix> sounds like you installed an update that changed the menu to restart, i dunno why it keeps being told to change it tho
[18:48] <Otacon22> Connect to session bus?
[18:48] <Otacon22> and then search for :1.72 ?
[18:48] <ohsix> yea
[18:49] <Otacon22> Unique Name: :1.72
[18:49] <Otacon22> Command Line: /usr/lib/indicator-session/indicator-session-service
[18:49] <Otacon22> indicator-session-service humm
[18:50] <ohsix> hm i'm mistaken then, i don't know what a null destination means
[18:53] <Otacon22> following the strace of indicator-session-service i see:
[18:53] <Otacon22> read(18, "\1\0\0\0\2\0\0\0\0\0\0\0 \0\0\0openvpn.client.s"..., 1024) = 48
[18:53] <Otacon22> read(18, 0x26372e0, 1024)               = -1 EAGAIN (Resource temporarily unavailable)
[18:53] <Otacon22> maybe some trouble with a vpn?
[18:55] <Otacon22> (the ram used by the indicator is still growing up)
[18:55] <ohsix> could be, i dunno why session service is taking all the memory though
[18:59] <Otacon22> What should i do? just kill and restart it or do you have some others ideas to try?
[19:08] <ohsix> i'm getting about 2 messages a minute to my session indicator
[19:08] <ohsix> ehh, you can kill it; i was more looking into an out & out direct cause of the memory growth
[19:45] <ttx> ari-tczew: pong?
[19:45] <ari-tczew> ttx: is it worth merging maven-ant-helper 7.2 from Debian?
[19:46] <ttx> ari-tczew: looking
[19:48] <ttx> ari-tczew: it's worth it only if we need it as a build-depend on something else
[19:48] <ttx> ari-tczew: so I'd wait until we actually *need* it
[19:49] <ari-tczew> ttx: there is no DEPWAIT on maven-ant-helper.
[19:49] <ttx> ari-tczew: right, so my answre would be: no. :)
[19:50] <ari-tczew> ttx: OK.