logs archiveIRC Archive / Freenode / #emacs / 2010 / March / 11 / 1
vanRijn
mjrosenb: I'm doing an "ssh user@host make ..."
ah, okay
mjrosenb: any reason to not just do both?
> 2>&1 ?
er... "ssh user@host make ..." > $f 2>&1, I meant
yeah, that works. awesome. thank you again, mjrosenb! =:)
mjrosenb
in compilation-finished-function, is there any way of determining if the window was spawned by the compile, or if it already existed?
quotemstr
Wow.
The EU parliament rejected ACTA 663 - 13.
Or not.
metaperl
what's ACTA?
quotemstr
Stupid sensational headline,
metaperl: A secret worldwide copyright treaty.
metaperl
YAY!
crossblaim
hi
quotemstr
Hrm.
For a stream-like interface, is it better to support peek()-like functionality --- something like read() that doesn't remove the copied bytes from the input stream --- or something like ungetc() ?
Both require arbitrarily-large buffers.
tromey
java's answer, which I think is kinda reasonable, was to require a wrapper object if you wanted pushback
on the theory, I think, that pushback is relatively rare in practice
         

dim
in theory, theory and practice are the same thing... not in practise.
ouch, not in practice
powr-toc
Does anyone know why my Emacs doesn't play nice when booting into tiling window managers? It lays things out (like the minibuffer) in the wrong place and I have to reorder the screen to sort it out
damd
i have that problem as well
there is some solution to it, i just can be bothered finding it again
the problem arose with emacs 23 iirc
dim
I use the awesome window-manager and it just works
,g aswesome window manager
fsbot
[google] http://ubuntuforums.org/archive/index.php/t-550240.html
http://www.stateparks.com/ledges.html
powr-toc
dim
mmm not there
quotemstr
tromey: That's one solution too, but the case I want to handle elegantly is "let's read a line, then read some randomly-sized chunks"
dim
quotemstr
tromey: (Say, we're using STARTTLS for an SMTP-style protocol.)
tromey: Now, we can read input lines one character at a time, but that's pretty slow.
tromey
do you need pushback for that though? or just ordinary buffering?
quotemstr
tromey: So if we instead read in chunks of 1024, we can just scan the chunk for the line; say the line is 8 characters long. What follows the line is random SSL crap.
powr-toc
dim: hmmm... not looked at awesome... any reason to choose it over xmonad?
quotemstr
tromey: We want to then pass this stream to the generic SSL handling code. What do we do with the extra 1016 bytes we read?
tromey: Another scenario is a lisp reader.
tromey
pass the buffered reader to the ssl handler
there are a lot of ways to do this of course
quotemstr
Say we're reading "12345'foo". We want to stop reading after the '5', but leave the ' for the next chunk of code to pick up.
tromey
yes, ISWYM
quotemstr
Yeah. Choice is hard. Thanks for the advice. :-)
tromey
:)
if you have a pretty generic buffered reader, supporting a single byte of pushback is cheap & easy, and suffices for those cases
quotemstr
Either a peek mechanism or a pushback one will work, but I don't see how you can do that elegantly with pure read()-like semantics.
Yeah, that's what I'll end up doing, probably.
         

tromey
yeah, I misunderstood the problem, sorry
quotemstr
Or six bytes, for a single UTF-8 character.
tromey
codecs usually add an extra layer of evilness
quotemstr
*Plus* I want to be able to install arbitrary filters between a source and its eventual consumer (say, ungzip).
And I want these filters to work equally well in the "push" direction too without having to write the filter twice. You see it becomes complicated. :-)
ams
hm.
quotemstr
ams: ?
ams
quotemstr: straighten up boy!
quotemstr
??
fsbot
I'm telling you, you don't want to know.
quotemstr
ams: Bite me.
ams
quotemstr: i love you too.
angstrom
what do i have to specify in my .emacs to show the curser position in the status-bar?
ams
angstrom: you mean you want a number where on which column your point is in th modeline?
skeptomai
angstrom: you mean the row and column?
isomer
angstrom: M-x line-number-mode RET
jlf
+: and column-number-mode
isomer
angstrom: and M-x column-number-mode RET
angstrom
line is displayed
ams
angstrom: column-number-mode
angstrom
awesome. thx guys
isomer
np
skeptomai
(setq-default line-number-mode t) in your .emacs
ams
angstrom: i'm a girl.
damd
why setq-default?
ams
damd: line-number-mode is local to the buffer.
angstrom
(Action) kisses ams's hand then
damd
but column-number-mode is not?
ams
angstrom: i'm a boy.
angstrom
oO
ams
damd: it is.
damd: i think...
a better way is to call the functions
damd
maybe the function `column-number-mode' does setq-default
ams
probobly not.
Intensity
Is there any way I can avoid MEM FULL errors altogether? Such as by increasing some parameter in the source code?
ams
Intensity: add more memory?
Intensity
ams: I have sufficient memory.
ams
Intensity: if you say so.
jeremyw
I've never gotten such an error from Emacs.
Intensity
jeremyw: Neither have I gotten that error before, prior to the 23.1 release. I also submitted a bug in the garbage collection engine. The backtrace of Emacs is thousands of functions deep. Memory management isn't working too well in the Emacs core.
ams
i have..
Intensity
Also, Emacs is consuming 100% CPU, just like it did last time I encountered the bug that warranted a bug report.
ams
Intensity: sounds like infinite recursion somewhere..
you smash the stack, the gc barfs because of it, and you get the error.
Intensity
ams: As long as the bug exists in the present version I am using, I'd be happy to avoid it. Emacs is using 1GB of RAM now, but I have 4GB and nothing else running. And in earlier Emacs versions I've used 3GB without a problem.
ams
Intensity: how about instead of trying to avoid the bug, figure out why i occurs?
Intensity
ams: I'd like to do both. I submitted a bug report when I encountered something similar before, but I don't see how a problem like this would be fixed quickly. The trigger seems to be using around 1GB of memory or so, whereas there's no OS limitation that suggests a limit like this should apply.
cluck
Intensity: we're not called Eight Megabytes And Constantly Swapping for nothing you know :)
jeremyw
haha
ams
Intensity: you are looking at the symptoms, and not the problem.
Intensity
cluck: Yeah, I'm happy with using this much memory. But I don't see how Emacs would be imposing this limitation on me.
ams: I was mentioning the trigger -- the commonality between the two instances. There seemed to be a garbage collection bug or a problem in the internal state of Emacs memory allocation.
jeremyw
How is this being reproduced?
ams
Intensity: i don't see where youmentioned how to trigger it, only how to avoid it.
jeremyw
That's what I just asked.
Intensity
jeremyw: I encounter this after several months uptime of Emacs, when overall memory usage of Emacs climbs. There does not seem to be one instantaneous trigger, except perhaps the point at which Emacs decides to do garbage collection.
ams: I do not know how to avoid it either.
ams
Intensity: how about you explain how you trigger it instead of repeating yourself?
jeremyw
Months of uptime? Wow.
Intensity
ams: I mentioned two messages ago that there is no apparent trigger except when Emacs decides to do garbage collection. There's no other apparent commonality here.
jlf
jeremyw: that's not uncommon around here :)
jeremyw
jlf: I guess not. I've gone weeks I guess. I don't really see the need to even go that long but "To each his/her own". :)
ams
Intensity: let me get this straight... you wish to avoid a serious bug, by ignoring it, where emacs has no means of saving itself by ignoring the messages printed... and you have no clue why it occurs... ok...
devinus
http://pastie.org/864171
how can i see that value "sr-speedbar-right-side" to nil ?
cluck
Intensity: currently i can't recall any known bug that causes that, if possible try to figure how and when that happens and report back the bug because it might be one of those "when the moon is in venus, the sun in jupiter and you were born in october and someone sneezes just right in september it crashes" hard to find kind of problem
ams
devinus: see or set?
devinus
set :)
ams
devinus: (setq ...)
devinus: please refer to the emacs manual, it explains all this.
jeremyw
From what I can see, Intensity is saying that memory just continues to grow and never releases. That's all I can see.
cluck
also, the GC isn't anywhere near perfect
shabble
Intensity: have you tried opening lots / really huge files to see if it'll reproduce any faster?
ams
ams 1261 0.1 12.2 84344 62416 tty2 S+ Mar07 5:10 emacs
shabble
waiting a couple of months for a testcase isn't exactly optimal :)
cluck
with big enough uptimes misbehaviors are bound to happen eventually
ams
shabble: why wait? just open lots of crap
quotemstr
cluck: Huh?
ams
not like uptime has any relevance on anything here...
shabble
ams: I think that was my point. :p
quotemstr
cluck: The GC is precise in Emacs.
ams
and what quotemstr said
quotemstr
cluck: For our purposes, it's perfect.
cluck: It's the *surrounding* code that's buggy.
If anything, GC errors tend to lead to crashes instead of leaks.
In Emacs, you tell the GC about roots; it assumes everything else is *not* a root. So if you forget to GCPRO something, it'll be GCed, and Emacs will die.
Slow leaks don't happen under that scheme.
ams
(Action) gives quotemstr a cookie
cluck
quotemstr: really? istr reading there were some stuff that couldn't be properly gc'ed, was that fixed? in any case i retract myself and am sorry if i misled anyone
quotemstr
cluck: I don't remember anything like that, but if you find that, by all means let me know.
Intensity
ams: I'd like to avoid the bug by lifting whatever limitations are causing Emacs to consider my memory as limited. In earlier pre-23.1 releases I wasn't even encountering this. I don't know what is triggering the problem, but I'm happy to do whatever I can to report the bug, such as providing a backtrace like I did last time.
cluck: Yes, I'll be reporting the trace and any information that I still can provide at this point. A backtrace of over ten thousand calls deep looks like something isn't working right internally.
ams
Intensity: you clearly do not understand, it is not the `limit on memory' here, it is simply that your stack somewhere gets fu*ked up, hence the 1000 function deep stack trace
Intensity: most probobly, it isn't even infinite recursion, but simple that the stack is refering back to it self, so that gdb gets confused and you get what looks as infinite
Intensity
ams: I can't verify your hypothesis that the stack has been altered. I don't see any evidence of infinite recursion.
ams
Intensity: uhm, a thousand level deep stack _IS_ infinite recursion
quotemstr
,apropos max.*depth
fsbot
3 matches. (max-lisp-eval-depth mkback-max-depth quail-completion-max-depth)
quotemstr
Ah, there we go.
,dv mix-lisp-eval-depth
fsbot
not documented as a variable.
quotemstr
,dv max-lisp-eval-depth
fsbot
*Limit on depth in `eval', `apply' and `funcall' before error.
This limit serves to catch infinite recursions for you before they cause
actual stack overflow in C, which would be fatal for Emacs.
You can safely make it considerably larger than its default value, ..[Type ,more]
quotemstr
Intensity: Go ahead, set that to most-positive-fixnum.
ams
Intensity: where do you have the bt?
quotemstr
Intensity: Watch Emacs crash.
Intensity
ams: I don't agree with you. That stack eventually unraveled itself. And I didn't necessarily see an additional error message printed to Emacs, such as seeing the eval depth exceeded.
ams
Intensity: where do you have the bt?
Geralt
Hi, is it possible to find out in elisp if emacs is running in daemon mode?
cluck
quotemstr: maybe i was confused, looking back at the ml archives i can't find anything, maybe i was mistaking it with the discussions on aggressive gc
Intensity
quotemstr: I don't think that raising the max-lisp-eval-depth is what I want here. Because I had been encountering the problem at around 1GB of memory, I thought that there was a memory based limitation that was causing Emacs to go into MEM FULL mode in the first place. Somewhere it is getting this perception, even though I have 3GB free.
ams
Geralt: (server-running-p server-name)
Intensity: where do you have the bt?
Intensity
ams: I'd have to find a place to post it that will accept a large file attachment. Do you have a suggestion on where I can post the trace?
ams
emacs-devel@, a website, fencepost.gnu.org if you have an account there
ams@gnu.org
Geralt
ams: thanks
cluck
fsbot: tell Intensity about paste
fsbot
Intensity: [->] lisppaste is, like, [0] an auto-announcing listing host (pastebin) <http://paste.lisp.org/new/emacs>, <http://emacswiki.org/wiki/lisppaste>
[1] see ,lisppaste.el for an Emacs interface, ..[Type ,more]
cluck
,more
fsbot
[2] if down, try <http://hpaste.org>, <http://pastebin.ca>, <http://imageshack.us>, <http://www.porsbo.org/pastebin> or <http://pastebin.com>,
[3] at http://www.emacswiki.org/cgi-bin/wiki.pl?pastebin
ams
night
Intensity
cluck: I used filebin.ca before. I was reminding myself which one it was. I'll use that one again.
cluck
whatever suits your fancy :)
Geralt
ams: why is server-running-p not autoloaded?
Intensity
cluck: It's uploading now. Two minutes to arrival.
cluck: See filebin.ca/fvksup
hanDerPeder
i just reinstalled emacs from trunk and now it doesn't find git.. any ideas where I should start looking for the cause?
devinus
im getting confused
i know C-c is Ctrl + 'c' but what is C-c C-s ?
what combo do i do that in?
hanDerPeder
ctrl + c then ctrl + s (you dont let go of ctrl)
e1f
look at your exec-path variable hanDerPeder
it's where emacs searches for binaries
c-h v exec-path
hanDerPeder
thanks, elf
k-man
in vba, it appears that "or" does not do short circuit evaluation, ie "if a or b then..." will evaluate b even if a is true
how do you emulate short circuit evaluation if the language does not support it?
twillis
vb didn't have short circuit until vb.net IIRC
k-man
if a and then if b? or something
isomer
k-man: yes, i beleive you will have to use a nested if
k-man
isomer: ok, thanks
ahh, maybe case statements might be a work around
hmmm
« prev 1 2 3 4 5 6 7 8 next »