<aeth>
_death: Special variables are pretty bad except for I/O streams
<aeth>
Which is probably why that's the main place where they're used in the standard.
<_death>
aeth: thoroughly disagree...
caltelt has quit [Quit: Leaving]
<aeth>
_death: They kill performance and they're full of surprises (which is why they have to have earmuffs).
caltelt has joined #lisp
Fare has quit [Ping timeout: 240 seconds]
<aeth>
When your feature fails at both performance and reliability, it's pretty niche
<aeth>
Most of the time they're used in CL code it's because CL lacks dynamically scoped globals, not because they're the right fit.
<aeth>
(portably lacks it)
<_death>
welp, you're entitled to your opinion.. me, I'll stick with CL :)
<aeth>
s/dynamically scoped/lexically scoped/
<aeth>
I had it backwards
<aeth>
_death: CL is a language for the programmer, not a language like Java, which is why it has stuff like gotos that 95% of the time are the wrong choice.
<pierpa>
we are all sticking with CL, notwithstanding its many warts
<aeth>
The only use for dynamic variables that I agree with are stream stuff like *standard-output*, *standard-input*, etc., but that's a useful use because otherwise you have to pass streams really deep into your many functions and write the program around it.
<aeth>
Most of the rest of the time if you want globals to get around having too many parameters, you'd want lexically scoped globals
<aeth>
(But globals in general are a bad idea, and CL programmers use them far too often.)
<_death>
aeth: I think you value things differently from the values Lisp tradition emphasizes, and so you miss out on basic things like the worth of special variables
<aeth>
_death: Every language in the 1980s made mistakes, even Lisp. Common Lisp has to keep compatibility with even pre-1980s Lisps. That means it has features that *should* be avoided in most code. That doesn't mean Lisp is bad. As for tradition, I've seen historic pre-structured-programming Lisp programs and they like to use stuff like PROG and GO.
<aeth>
And like I said, Lisp isn't Java. Even if something is 99% of the time a bad idea, Lisp will have it there for the 1% of the time, like goto.
<_death>
aeth: like I said, you have a blind spot for certain values and that makes you see things as a "mistake".. special variables are indispensable when you want to write programs that are actually interactive languages for solving problems
<aeth>
_death: As I said before, sSpecial variables kill performance and reliability.
<aeth>
*special
smurfrobot has joined #lisp
<aeth>
Obviously programs that care about neither can still use them, and they are still useful in niches like streams.
<_death>
and I think you're wrong about that as well.. but I've no reason to believe anything I say right now can change it
<Bike>
why do these debates always start with stupid shit like naming
<Bike>
i have enough sheds
<aeth>
_death: You can't change my mind because I have written multithreaded CL, where globals *really* start to become unreliable.
<aeth>
There they're useless even for quick hacks
<_death>
aeth: you're not the only programming in the world to have written multithreaded CL :)
<_death>
*programmer
smurfrobot has quit [Ping timeout: 260 seconds]
mindCrime has joined #lisp
pierpal has quit [Ping timeout: 240 seconds]
lumm has quit [Quit: lumm]
Kundry_Wag has quit [Remote host closed the connection]
<no-defun-allowed>
are there any fancy clustering packages for CL?
pioneer42 has joined #lisp
<no-defun-allowed>
like lparallel but for multiple machines
<_death>
lfarm?
<no-defun-allowed>
yeah, i remember seeing one, might have been that
<no-defun-allowed>
looks perfect, ty
al-damiri has quit [Quit: Connection closed for inactivity]
nowhere_man has quit [Remote host closed the connection]
nowhere_man has joined #lisp
ninegrid has quit [Remote host closed the connection]
lemo has joined #lisp
dddddd has quit [Remote host closed the connection]
jusss has joined #lisp
captgector is now known as gector
karlosz has joined #lisp
Kundry_Wag_ has quit [Remote host closed the connection]
Oladon has joined #lisp
nickenchuggets has quit [Read error: Connection reset by peer]
karlosz has quit [Ping timeout: 260 seconds]
slyrus_ has quit [Ping timeout: 256 seconds]
smurfrobot has joined #lisp
karlosz has joined #lisp
dented42 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Kundry_Wag has joined #lisp
smurfrobot has quit [Ping timeout: 244 seconds]
vultyre has joined #lisp
fikka has joined #lisp
vultyre has quit [Client Quit]
Kundry_Wag has quit [Ping timeout: 248 seconds]
slyrus_ has joined #lisp
robotoad has quit [Quit: robotoad]
fikka has quit [Ping timeout: 240 seconds]
makomo_ has joined #lisp
milanj has quit [Quit: This computer has gone to sleep]
mindCrime has quit [Ping timeout: 260 seconds]
makomo has quit [Ping timeout: 268 seconds]
orivej has quit [Ping timeout: 264 seconds]
pierpal has joined #lisp
Kundry_Wag has joined #lisp
housel has quit [Read error: Connection reset by peer]
mindCrime has joined #lisp
robotoad has joined #lisp
pioneer42 has left #lisp [#lisp]
asarch has joined #lisp
mindCrime has quit [Ping timeout: 244 seconds]
eli_oat has joined #lisp
eli_oat has quit [Client Quit]
eli_oat has joined #lisp
Jesin has quit [Quit: Leaving]
eli_oat has quit [Quit: eli_oat]
eli_oat has joined #lisp
didi has left #lisp ["there are always reasons to /part"]
dented42 has joined #lisp
eminhi has joined #lisp
eli_oat has quit [Client Quit]
eli_oat has joined #lisp
eli_oat has quit [Client Quit]
eli_oat has joined #lisp
Kundry_Wag has quit [Ping timeout: 268 seconds]
dented42 has quit [Ping timeout: 260 seconds]
papachan has quit [Quit: Leaving]
milanj has joined #lisp
karlosz has quit [Quit: karlosz]
karlosz has joined #lisp
karswell has quit [Read error: Connection reset by peer]
karswell_ has joined #lisp
makomo_ has quit [Ping timeout: 260 seconds]
asarch has quit [Ping timeout: 256 seconds]
fikka has joined #lisp
Pixel_Outlaw has joined #lisp
beach has joined #lisp
<beach>
Good morning everyone!
mindCrime has joined #lisp
<beach>
jasom: You may be right. But as Bike and jackdaniel pointed out, I haven't given foreign code much thought.
housel has joined #lisp
fikka has quit [Ping timeout: 256 seconds]
pierpa has quit [Quit: Page closed]
mindCrime has quit [Ping timeout: 256 seconds]
<LdBeth>
Good afternoon
equwal has joined #lisp
equwal has quit [Remote host closed the connection]
dented42 has joined #lisp
scottj has quit [Quit: leaving]
SaganMan is now known as happiness
happiness is now known as SaganMan
smurfrobot has joined #lisp
SaganMan is now known as smiling
<beach>
I am making progress on my IR viewer. Next, I will improve the layout of control arcs that go to other places than the successor instruction: http://metamodular.com/IR-viewer.png
Pixel_Outlaw has quit [Remote host closed the connection]
smiling is now known as SaganMan
pierpal has quit [Quit: Poof]
pierpal has joined #lisp
nowhere_man has quit [Remote host closed the connection]
Kundry_Wag has joined #lisp
nowhere_man has joined #lisp
fikka has joined #lisp
eli_oat has quit [Quit: eli_oat]
eli_oat has joined #lisp
<beach>
scymtym: I had an interesting idea for Concrete Syntax Trees. In CST-FROM-EXPRESSION we normally don't get source locations. But we could pretty-print the expression to a string and use the source locations in that string to store in the CST.
lemo has quit [Quit: lemo]
lemo has joined #lisp
fikka has quit [Ping timeout: 256 seconds]
smurfrobot has quit [Remote host closed the connection]
lemo has quit [Quit: lemo]
lemo has joined #lisp
eli_oat has quit [Quit: eli_oat]
eli_oat has joined #lisp
EvW has joined #lisp
Bike has quit [Quit: Lost terminal]
lemo has quit [Changing host]
lemo has joined #lisp
lemo has quit [Quit: lemo]
lemo has joined #lisp
lemo has quit [Changing host]
lemo has joined #lisp
EvW has quit [Ping timeout: 248 seconds]
saki has quit [Read error: Connection reset by peer]
karswell_ has quit [Remote host closed the connection]
<kenster>
I need to stop programming 12 hours a day, I'm such an idiot sometimes
anewuser has quit [Ping timeout: 268 seconds]
Fare has joined #lisp
nowhere_man has quit [Ping timeout: 256 seconds]
fikka has joined #lisp
moei has quit [Quit: Leaving...]
mange has quit [Remote host closed the connection]
moei has joined #lisp
<Zhivago>
Less programming; more engineering.
HeyFlash has joined #lisp
smurfrobot has joined #lisp
pierpal has quit [Quit: Poof]
pierpal has joined #lisp
Lauven has quit [Quit: leaving]
daniel-s has quit [Ping timeout: 244 seconds]
<beach>
scymtym: I am currently testing my IR viewer and I would like to see source code associated with the HIR code. More generally, imagine someone typing forms to the REPL and there is an error. It would be good to have source information so that the place of the error can be shown as source.
milanj has joined #lisp
varjagg has joined #lisp
<beach>
Speaking of FFI, there was a very interesting article in the July 2018 issue of CACM entitled "C is not a low-level language". It was about how processors today use vast amount of energy and silicon real estate in order to make C programmers believe that they are still dealing with the PDP-11 semantics of execution.
<beach>
The article also talked about the complexity of a typical C compiler in order to make the C semantics fast enough on current processors.
<beach>
It made me wonder how we (Common Lisp implementers) are able simplify our compilers compared to C compilers such as Clang and LLVM since there are many restrictions in C that we don't have in Common Lisp.
Kundry_Wag has joined #lisp
smurfrobot has quit [Remote host closed the connection]
Fare has quit [Ping timeout: 240 seconds]
Kundry_Wag has quit [Ping timeout: 244 seconds]
fikka has quit [Ping timeout: 240 seconds]
caltelt has quit [Ping timeout: 256 seconds]
fikka has joined #lisp
SaganMan has quit [Ping timeout: 256 seconds]
nowhere_man has joined #lisp
knusbaum has quit [Ping timeout: 264 seconds]
daedreth-notUD has joined #lisp
daedreth-notUD has quit [Client Quit]
daedreth-notUD has joined #lisp
<daedreth-notUD>
Anyone here at this time?
<beach>
Of course.
<daedreth-notUD>
HeyHo
<daedreth-notUD>
I'm having trouble with quicklisp.
<beach>
Could you be more specific?
<LdBeth>
z.
<daedreth-notUD>
* (quicklisp-quicksart:install)
<daedreth-notUD>
debugger invoked on a SB-INT:SIMPLE-READER-PACKAGE-ERROR in thread
<daedreth-notUD>
Package QUICKLISP-QUICKSART does not exist.
<aeth>
quicksart?
<aeth>
did you mean quickstart?
<daedreth-notUD>
ahem
makomo_ has joined #lisp
<beach>
daedreth-notUD: Don't feel bad. I am turning increasingly dyslexic and I often make mistakes like that without being able to spot the problem.
<LdBeth>
I’m thinking about bring “Do what I mean” feature back to Common Lisp
<aeth>
It actually would be a nice feature if it did that like some terminals do.
<aeth>
Either at the implementation (SBCL) level or in SLIME
<aeth>
My terminal also offers to install packages if they're missing. e.g. if I type "units" and it's not installed, it will find the package that provides "units" and offer to install it. That would be a bit tricky in CL, though, because multiple systems can provide the same-named package.
<aeth>
(obviously you'd have to sudo in the terminal example)
<daedreth-notUD>
ok, the actual problem is when trying to create a quicklisp project.
<aeth>
And, actually, I think some compilers these days do a similar "did you mean foo" when you try to compile code with an undefined variable "goo" or whatever.
eschulte_ has quit [Ping timeout: 240 seconds]
<daedreth-notUD>
after evaluating (ql:quickload :quickproject) it says "Package QL does not exist."
<daedreth-notUD>
it worked seemlessly on my other machine, but I messed something up on my laptop.
eschulte has joined #lisp
<aeth>
What does your ~/.sbclrc look like?
<beach>
You must have forgotten a form in your .sbclrc.
<LdBeth>
CL is dynamic typed, so reference a variable before initializing it should be allowed. So I believe it has to be embedded to run time.
<aeth>
(I'm assuming SBCL because your error had SB-INT in it)
<aeth>
LdBeth: In CL it's a warning, not an error
<aeth>
And it's more about potential future globals in the mutuable-at-runtime global state afaik
<aeth>
(Although they *should* have earmuffs)
<daedreth-notUD>
I like the earmuffs. Everyone who doesn't use them deserved to burn in the hellfires of iterative programing.
<beach>
LdBeth: It is not possible to create an uninitialized variable in Common Lisp. Besides, how does it follow from dynamic typing that such a thing would be allowed?
<aeth>
(defun foo () bar) ; warning about bar being undefined
<aeth>
(defvar bar 42) ; now (foo) will work, but you should have put earmuffs on bar in the first place
<beach>
daedreth-notUD: Why the aggressive tone of voice?
<daedreth-notUD>
I'm just joking.
<daedreth-notUD>
I'm a calm sheep.
kenster has quit [Ping timeout: 248 seconds]
<beach>
LdBeth: Well, I guess you can create a variable with no value, so yes, that's uninitialized. But you can't refer to it until you assigned to it.
<aeth>
LdBeth: Anyway, that doesn't have to do with dynamic typing, that has to do with being able to add global variables after the function was compiled and then the function having to respect that.
<daedreth-notUD>
Does someone here know, where my sbcl configuration lies?
<beach>
daedreth-notUD: You were told already: ~/.sbclrc
<daedreth-notUD>
I should pay more attention.
<daedreth-notUD>
ty
<beach>
ywlcm
<daedreth-notUD>
my ~/.sbclrc looks non existent
<aeth>
daedreth-notUD: what is your OS?
<beach>
That would explain the problem.
<daedreth-notUD>
Arch Linux
nickenchuggets has joined #lisp
nickenchuggets has joined #lisp
nickenchuggets has quit [Changing host]
milanj has quit [Quit: This computer has gone to sleep]
<LdBeth>
aeth: my bad. I mean “many things are decided at runtime”, which seems close to dynamic typing.
Kundry_Wag has joined #lisp
angavrilov has joined #lisp
<daedreth-notUD>
My problem is not with my .sbcl directory, because my other machine also doesn't have it.
Kundry_Wag has quit [Ping timeout: 256 seconds]
<beach>
daedreth-notUD: It is a file and it is called .sbclrc and it is in your home directory. There is typically no .sbcl directory.
<scymtym>
beach: code entered at the repl must still be READ. why not associate source locations at that point?
<daedreth-notUD>
I was looking for a directory my bad.
<daedreth-notUD>
I think I might've fixed it.
<beach>
scymtym: Wouldn't that require modifying the REPL?
<daedreth-notUD>
I just removed the "Quicklisp" directory in my home directory
daedreth-notUD has quit [Remote host closed the connection]
Kundry_Wag has joined #lisp
daedreth-notUD has joined #lisp
<beach>
daedreth-notUD: There should be a directory named "quicklisp" and not "Quicklisp".
<scymtym>
beach: ok, let's take a step back. is this the SICL REPL or some host's? how is the HIR produced form the REPL input?
<daedreth-notUD>
then I remebered it badly.
<scymtym>
*produced from
<beach>
scymtym: Sorry, I should have been more clear. I was just thinking of the SBCL REPL when I type (cst:cst-from-hir '(...))
<beach>
I take the CST produced that way, and put it through CST-TO-AST and AST-TO-HIR.
<aeth>
LdBeth: I have to nitpick again. Dynamic typing often works at compile time, through type inference.
<beach>
scymtym: You are right of course. No such thing would be needed in a new system.
<daedreth-notUD>
Everything works now. I somehow messed up my ~/quicklisp folder.
<daedreth-notUD>
sorry for bothering you, but you helped me a lot in finding the error.
<daedreth-notUD>
:D
<beach>
daedreth-notUD: Not a problem. Good luck.
<scymtym>
beach: did you mean cst:cst-from-EXPRESSION in the initial step?
<beach>
Ouch, yes.
Kundry_Wag has quit [Ping timeout: 256 seconds]
<beach>
I guess I am not quite awake yet, despite having been to the store and all.
<scymtym>
ok, i understand then
smurfrobot has joined #lisp
<scymtym>
how about making a simple REPL that READs using eclector and displays the visualization for each input?
<beach>
The thing is not a big deal. I was just playing with my IR viewer and it would be nice to see the source. I can fix that by reading from a file at the momentn of course.
<beach>
Yeah, I can do that.
<beach>
scymtym: The other idea I had this morning was to bite the bullet and create a first-class global environment tailored to SBCL.
<beach>
That way I wouldn't have to go through the work to create a complete SICL environment each time I want to create some HIR code in SBCL.
<beach>
Besides, there have been discussions abut a Cleavir-based compiler for SBCL.
<scymtym>
such a fcge would take macros, global functions, etc. from the host?
<beach>
Most macros and functions would just be imported, but a few would have to be customized like MACROEXPAND-1 and macros that explicitly call the macro expander.
<beach>
Yeah, most.
<beach>
I think the list of specific stuff would be reasonably small.
<trittweiler>
beach: the CST are just the READ forms? You can perhaps use an EQ hash-table to associate something with a read form, and retrieve from that hash-table later? (Assuming you have access to the originally read form from within later in the compiler)
daedreth-notUD has left #lisp ["ERC (IRC client for Emacs 26.1)"]
<beach>
trittweiler: The CST already has better source tracking than what a hash table can do.
<scymtym>
on the bright side, separate code for macroexpansion open the door for source tracking through macroexpansion
fikka has quit [Ping timeout: 256 seconds]
<beach>
scymtym: Indeed.
fikka has joined #lisp
<beach>
trittweiler: But creating the CST requires the use of the Eclector reader and it has to use a stream that supplies source location.
<scymtym>
depending on how source locations are represented, that can be true for most standard streams, though
schweers has joined #lisp
<beach>
It could.
<scymtym>
the default implementation make a cons of the FILE-POSITIONs at the start and the end, so it only needs a working FILE-POSITION
<beach>
But I know how I want to do it in SICL, and that requires a bit more work. I want the source location to have several components, the line number, the column number of the beginning and the end of the expression, and a vector of strings that contains the text of the file.
<beach>
The vector of strings would be shared by all source locations in a file of course.
<beach>
scymtym: True.
<scymtym>
sure, there are many ways to do source locations
<beach>
This one would always be very precise though. Even if the original source file is absent or if it has been modified, this technique will show the right position.
<scymtym>
i agree. i also store the file content in (or rather shared between) source locations
<beach>
scymtym: Are you talking SBCL now, or your own experimental compiler?
<jmercouris>
why does my factorial function return different results with an int vs a float
<jmercouris>
the value is the same, but the representation is different
<beach>
jmercouris: It has to do with the limited precision of floats.
<beach>
jmercouris: It has to do with floating-point contagion.
<beach>
jmercouris: When you use a float in an operation together with an integer, the integer is converted to a float and then the operation is done with floats.
<jmercouris>
I thought lisp had some special type of numbers that maintain all accuracy
<beach>
Not floats. Only integers.
<jmercouris>
like you can use 3/4's and it won't be approximated to 0.6666
<beach>
Right, you can use ratios.
<jmercouris>
so integers have infinite precision?
<jmercouris>
or no?
<beach>
But once you use a float, everything is going to float.
<beach>
Yes.
<jmercouris>
I see
<jmercouris>
so why would you ever use floats?
<jackdaniel>
jmercouris: Lisp has bignums, which may be arbitrary big
<beach>
Not infinite, but arbitrary.
<jackdaniel>
but it would be hard to find infinite memory to contain infinite integer
<beach>
jmercouris: Floats are very fast.
<beach>
jmercouris: The processor has a lot of transistors for floating-point operations.
<jmercouris>
that's true, for most processors at least
<beach>
jmercouris: Not so many (zero in fact) for bignums.
<jmercouris>
I remember on the first androids, there was only virtualized float operations
<jmercouris>
those were incredibly slow
<jmercouris>
led to some interesting ways of writing game engines
<jackdaniel>
you mean ARM processors without fpe?
<jmercouris>
Maybe, it's been a long time, I can't quite remember
kajo has joined #lisp
<jackdaniel>
it is not android-specific
<jackdaniel>
if you put "normal" Linux on such soc you'd have emulation as well
<jmercouris>
if floats are less precision why you would want to do that kind of casting
<jmercouris>
normally it feels like things are cast to higher precision when possible for operations
<jmercouris>
the only exception I can think of this is significant figures, which has a completely separate context
<jackdaniel>
precision often comes with a performance penalty cost
nowhere_man has joined #lisp
<jackdaniel>
for sake of good fps in games it is arguably fine to approximate PI with 3 (three) (of course I'm half-joking, but only half)
<beach>
jmercouris: If you try to add a bignum and a float, the result is very likely not going to be an integer. So you do the conversion first, and then use the fast hardware to add.
<jmercouris>
jackdaniel: I've done worst
<jmercouris>
beach: I see
<beach>
jmercouris: Plus, again if you try to add a bignum and a float, the float has limited precision by design. There is no point in trying to maintain a higher precision than the precision of the least precise of the two operands.
<beach>
jmercouris: You would get a number with a large number of significant digits, most of which would be wrong.
<jmercouris>
I see
<jmercouris>
the system has no way to distinguish that 20.0 = 20
<jmercouris>
and that actually 20.0 is not just a loss of information, right?
<jmercouris>
and really the value is perhaps 20.0000000000000000000000000000000001
<jmercouris>
or am I misunderstanding?
<jackdaniel>
eql will tell you they are different
<jackdaniel>
but (= 20.0 20) returns T here
<pjb>
jmercouris: IEEE 754 single float have only 24 bits and double floats only 53 bits of significant digits.
smurfrobot has quit [Remote host closed the connection]
<jackdaniel>
that said, doing = on floats is a bad idea, always use <= or >=
<aeth>
jackdaniel: 3.14 is probably good enough
<jackdaniel>
and 3 is even better ;)
<jmercouris>
of course it can eql 20.0 against 20, I'm trying to reconcile what beach said about no point in maintaining a higher degree of precision
<aeth>
Eh, in the old days they'd do things like 22/7 (surprisingly close: you get 3.14... from it)
<beach>
jmercouris: 20.0 is a special case. It has an exact representation in float.
fikka has quit [Ping timeout: 244 seconds]
orivej has joined #lisp
Kundry_Wag has joined #lisp
Kundry_Wag has quit [Ping timeout: 260 seconds]
kajo has quit [Quit: From my rotting body, flowers shall grow and I am in them and that is eternity. -- E. M.]
<beach>
jmercouris: Here is something you can try: (defun f (x) (multiple-value-bind (m e) (integer-decode-float x) (* m (expt 2 e))))
<beach>
(then try (f 20.0), (f 200.0) etc, until you don't get the integer value back.
<beach>
For single floats on SBCL, doing (f 200000000000.0) will show you.
<jmercouris>
Yes, I see it now
<jmercouris>
very strange
<beach>
Not at all.
<jmercouris>
very unexpected by myself specifically
<jmercouris>
:D
<beach>
As long as your integer has no more significant digits that the floating-point precision allows, you have an exact representation of the integer as a float.
<beach>
When your integer requires more significant digits than that, the float must be an approximation.
jusss has quit [Quit: ERC Version 5.3 (IRC client for Emacs)]
<jmercouris>
that does make sense
<beach>
The proof is simple actually. Since floats are represented as a mantissa between 0.5 and 1 plus an exponent (power of 2), for a small integer, you can obtain the floating point by shifting right until the number is less than 1, and the exponent becomes the number of positions shifted.
<beach>
That is in fact what my program is doing.
<beach>
Or the inverse, to be precise.
smokeink has quit [Ping timeout: 244 seconds]
<beach>
But if you need to shift more times than there are bits in the representation of the mantissa, you lose the least significant digits.
<jmercouris>
I think you lost me there
<jmercouris>
what is a mantissa?
<beach>
Not important.
<beach>
You need to read up on floating-point numbers.
<jmercouris>
I'll get there slowly in my book, I believe they are in there
<beach>
They call it "significand" there, but it is sometimes called "mantissa".
<beach>
But this is very likely too much math for you so just drop it and trust me.
<jmercouris>
:D
<jmercouris>
I can't tell if you are being sarcastic, condescending, or serious
<beach>
I was being serious, given what you said the other day.
<jmercouris>
It is not as if I don't understand floating point numbers, I had to learn about them in my undergraduate even
<jmercouris>
based on what I'd read in books about lisp, I'd been led to believe that lisp has its own structures for representing numbers
<beach>
But you never heard the word "mantissa"? Strange!
<jackdaniel>
if you don't know what mantissa is – it is hard to believe you understand floating point numbers
<jmercouris>
and that a float in lisp, was never actually a float
<beach>
jmercouris: Most Common Lisp systems use IEEE floats.
<jmercouris>
I'm sorry I don't remember everything from my undergraduate, it was some time ago
<jmercouris>
but there was a time in the past, in which I most definitely understood what floats were
<jackdaniel>
floating point number is a well estabilished term. it could be that some Lisp didn't use IEEE floats for floats, but that does not mean that floats weren't floats (tautology?)
schweers has quit [Remote host closed the connection]
<pjb>
How can one forget what floats are once you know it? It's like bicycle driving!
<TMA>
you do not really know for the most part
fikka has joined #lisp
lemo has joined #lisp
lemo has quit [Changing host]
lemo has joined #lisp
papachan has joined #lisp
Kundry_Wag has joined #lisp
<beach>
Hmm. I am specifying my GUI tools as if the width has to be at most 1600 pixels (i.e. what I currently have on one of my two monitors), but soon I will buy a 4k monitor in addition to those, and then it is reasonable to make the applications twice as wide.
<beach>
Now, what do I do in order to take into account more common configurations at the same time as I take advantage of better ones?
<beach>
I mean, one of the most common complaints about Emacs is that it creates windows in any location, and that buffers are not shown in the same window all the time.
<beach>
So an obvious solution to that problem for the tools I am planning is to have fixed locations for the windows.
<beach>
But I don't see how to make that work at the same time as I take into account different numbers of pixels at the user's disposal.
test1600 has quit [Quit: Leaving]
<joga>
(people complain about being able to have multiple windows?)
<beach>
That's not what I meant.
<beach>
I'll give you an example: I would like to have my REPL window on the right half and any buffer that I edit on the left.
<beach>
But, now say an error is signaled during execution.
<beach>
Then the backtrace window will hide the buffer window, which I can accept.
<joga>
ah I mistook you meaning an entirely separate X window instead of emacs window
<beach>
But then if I hit `v' on a frame, the frame will be displayed in place of the REPL.
<pjb>
beach: don't work in pixel, work in point. 1 point = 1/72 inch.
<beach>
Even if I invoke the quit restart, my repl window will not come back, and I often have my buffer displayed in both windows.
daedreth-notUD has joined #lisp
<pjb>
computersknow the actual area of their screens, since screens report their DPI.
<beach>
pjb: And how is that going to solve my problem? Either I won't be able to use my additional screen real estate, or a normal configuration will be unreadable.
<pjb>
This is what we have eg. in Display Postscript.
<pjb>
And of course, use windows. They're invented for that, to be independent from the actual size and configuration of screens.
<beach>
... which is the complaint that I was trying to avoid.
eminhi has joined #lisp
<pjb>
Well, otherwise you have a different style. More like what is achieved currently by Windows 10 (which is not bad, graphically).
<beach>
I have never used Windows 10. The last one I used (briefly) was NT.
<pjb>
So you specify your UI in terms of panes, and those panes are arranged (and sized too) automatically depending on the screen surface.
<pjb>
It looks like the Startrek UI :-)
<beach>
So some of them will just not be present on small screens?
<beach>
Doesn't sound useful.
<pjb>
The panes are generally oversized, because they cater to touch-UI.
<pjb>
So you can easily scroll to see everything on small screens.
<beach>
Yeah, not acceptable.
<pjb>
On laptops, we now also have trackpads, and on desktop Apple provides also trackpads, so scrolling and sizing is easy.
<joga>
I use a tabbed, tiling window manager to handle window placement and it's rock solid with any screen size, but doesn't exactly solve emacs windowing hurdles by itself unless you have emacs spawn all the windows you need
<beach>
Hold your mouse over an item on the left. Try to scroll to see the explanation on the right.
<beach>
I guess I am not expressing myself very well today. It is no wonder, given two power cuts during the night and two additional computer crashes this morning. Makes it hard to concentrate.
<pjb>
In conclusion, I guess what I mean here is that user interfaces are in flux, and application should detach themselves from the need to micromanage the user interface. The application should provide high level data elements, and the system (or a library) should decide how to present them and how the user interact with the interface, depending on the available hardware, and the user preferences.
<beach>
I think I will be quit and go think about my problem on my own.
<pjb>
You don't need to display the same decorations when you have spoken commands, than when you use a mouse, or when you use a trackpad.
<pjb>
eg. with the mouse, you want to show thew scroll bar all the time. With a trackpad, you don't need as scroll bar, because you can easily scroll with two finger drag.
<pjb>
(and if you use a pen on a table, it still different).
saki has joined #lisp
Kundry_Wag has quit [Remote host closed the connection]
Kundry_Wag has joined #lisp
<sailor_cat>
Hi there
<sailor_cat>
I have a question about lisp's performance
<sailor_cat>
now I'm looking for a best shell script to change bash
<sailor_cat>
and I'v decided to check performance of sbcl
<sailor_cat>
just because I can
<sailor_cat>
I've made a simple test: check a value of one point of Mandelbrot set by naive algorithm
<sailor_cat>
on python and on lisp do a same amount of iteration and check time
<sailor_cat>
I've expected that sbcl will provide better (maybe 1.5x better result), but not.
<sailor_cat>
So, I'm not a real lisper. I only read the Practical Common Lisp few years ago and I need somebody who can explain it
pierpal has quit [Remote host closed the connection]
lemo has quit [Read error: Connection reset by peer]
lemo has joined #lisp
orivej has quit [Ping timeout: 256 seconds]
<sailor_cat>
first column is number of iterations as 10^i, then lisp results (mandelbrot, mandelbrot2 and mandelbrot3), then python result, then scala
<sailor_cat>
Scala is dramaticaly faster, that's ok
<sailor_cat>
But python3 is faster too
<sailor_cat>
And also here I see no benefits for type declaration
<sailor_cat>
like in last line 123sec without types and 113 with them.
BitPuffin has joined #lisp
<sailor_cat>
Could you please explain is it normal, or I did something wrong?
<Xof>
without thinking very hard about this: the type COMPLEX that you are using is still quite a generic type
<Xof>
it includes things like (COMPLEX RATIONAL)
<Xof>
which is a complex number with arbitrary-precision components
<Xof>
if you change the binding of z0 to #c(0.0 0.0), and the declarations of complex to (complex single-float), maybe you get faster answers
<Xof>
(the compiler notes you get from compiling your code should be telling you that the compiler wasn't able to optimize everything fully)
rumbler31 has joined #lisp
<Xof>
probably a more minor thing, again without thinking hard or trying your code: just because n is a fixnum doesn't mean that (1- n) is a fixnum, in general
<Xof>
since you're probably only going to call those functions with non-negative n, you could say so: declaring n as (type (and fixnum unsigned-byte) n)
<sailor_cat>
ok, let me try
<Xof>
(that second one only helps mandelbrot2 with its downward-counting loop)
shrdlu68 has joined #lisp
HeyFlash has quit [Ping timeout: 244 seconds]
Josh_2 has joined #lisp
eminhi has quit [Quit: leaving]
EvW1 has quit [Ping timeout: 265 seconds]
<Xof>
you may also need to declare the type of z as (complex single-float) explicitly
shrdlu68 has quit [Ping timeout: 244 seconds]
shrdlu68 has joined #lisp
phoe_ has joined #lisp
vaporatorius__ has joined #lisp
vap1 has quit [Ping timeout: 240 seconds]
smurfrobot has quit [Remote host closed the connection]
Bike has joined #lisp
fikka has quit [Ping timeout: 240 seconds]
eschulte has quit [Ping timeout: 264 seconds]
Fare has joined #lisp
<Xof>
(if I do these things here, I get a factor of ~16 speedup with n=10^9)
lumm has quit [Read error: Connection reset by peer]
<Xof>
always always read the compiler notes
nsrahmad has left #lisp ["Leaving"]
smurfrobot has joined #lisp
starman_jr has quit [Ping timeout: 256 seconds]
<sailor_cat>
is there a good manual about "how make a fast lisp program"?
starman_jr has joined #lisp
<Zhivago>
(1) avoid doing unnecessary work.
<Zhivago>
(2) see (1).
<dlowe>
vacuous advice.
nsrahmad has joined #lisp
<dlowe>
sailor_cat: most of the techniques on making a fast program generally apply, though you may encounter tradeoffs with memory.
<dlowe>
sailor_cat: optimization on lisp specifically involves cajoling the compiler into making fast code (with declarations and fast-pathed forms), and being easy on the garbage collector
trittweiler has quit [Ping timeout: 240 seconds]
<dlowe>
and both of those tend to be implementation specific
<_death>
I wanted to point out sbcl's manual.. but seems sbcl.org is down
<dlowe>
automatic garbage collection does mean that the memory/speed tradeoff can be a lot more complex if you repeatedly allocate and abandon objects
<dwrngr>
It's up for me, although it took a while to resolve
<_death>
ah, it points out to the cmucl manual..
<dwrngr>
It was down yesterday and the day before for at least 20 hours
<dwrngr>
So I guess the general advice is just try for a couple of days until you get it, which makes it a tough sell in terms of reliability :P
<_death>
dwrngr: heh, now it seems to work again
<dwrngr>
Hard to believe sourceforge has fallen so far
<dwrngr>
Or maybe expectations are just much higher now, heh
smurfrobot has quit [Remote host closed the connection]
FreeBirdLjj has joined #lisp
jsjolen has joined #lisp
<jsjolen>
In a CLHS issue: "Compiler writers who didn't want to handle this won't go to sleep every night in fear that they really should have and that some day someone will be knocking on their door asking why not."
FreeBirdLjj has quit [Ping timeout: 244 seconds]
eschulte has quit [Ping timeout: 248 seconds]
<jackdaniel>
yes, common fear
dwrngr has quit [Read error: Connection reset by peer]
<dlowe>
sourceforge has been crap since 2001
<sailor_cat>
thanks a lot for your advices
mindCrime has joined #lisp
eschulte has joined #lisp
eli_oat has joined #lisp
_cosmonaut_ has quit [Ping timeout: 260 seconds]
Kundry_Wag has quit [Remote host closed the connection]
<Xof>
sbcl.org being down is not sourceforge's fault
<flip214>
but that's not an optimal solution either... I understand your window/buffer movement/ordering issues.
Pixel_Outlaw has left #lisp ["ERC (IRC client for Emacs 25.3.1)"]
<beach>
flip214: I see, thanks.
Kevslinger has joined #lisp
jibanes has quit [Ping timeout: 264 seconds]
smurfrobot has quit [Remote host closed the connection]
<v0|d>
Xof: what seems to be the problem?
sjl_ has quit [Ping timeout: 256 seconds]
Kundry_Wag_ has quit [Ping timeout: 260 seconds]
jibanes has joined #lisp
Inline has joined #lisp
pierpal has joined #lisp
nsrahmad has quit [Quit: Leaving]
rozenglass has quit [Read error: Connection reset by peer]
FreeBirdLjj has joined #lisp
nowhereman_ has quit [Remote host closed the connection]
nowhereman_ has joined #lisp
sjl_ has joined #lisp
trittweiler has joined #lisp
mindCrime has quit [Ping timeout: 240 seconds]
flazh has joined #lisp
sailor_cat has quit [Read error: Connection reset by peer]
shrdlu68 has quit [Ping timeout: 240 seconds]
kuwze has joined #lisp
shrdlu68 has joined #lisp
biopandemic has joined #lisp
rippa has joined #lisp
saki has quit [Read error: Connection reset by peer]
flamebeard has quit []
nowhereman_ has quit [Remote host closed the connection]
nowhereman_ has joined #lisp
sailor_cat has joined #lisp
pagnol has quit [Ping timeout: 256 seconds]
lemo has quit [Changing host]
lemo has joined #lisp
happy-dude has joined #lisp
eli_oat has quit [Ping timeout: 248 seconds]
cage_ has joined #lisp
smurfrobot has joined #lisp
_cosmonaut_1 has joined #lisp
_cosmonaut_ has quit [Ping timeout: 244 seconds]
nsrahmad has joined #lisp
smurfrobot has quit [Ping timeout: 248 seconds]
_cosmonaut_1 has quit [Ping timeout: 260 seconds]
eminhi has joined #lisp
robotoad has joined #lisp
nika has joined #lisp
knusbaum has quit [Ping timeout: 264 seconds]
eli_oat has joined #lisp
daedreth-notUD has quit [Remote host closed the connection]
eli_oat has quit [Remote host closed the connection]
mindCrime has joined #lisp
eli_oat has joined #lisp
smurfrobot has joined #lisp
kenster has joined #lisp
smurfrobot has quit [Ping timeout: 256 seconds]
fikka has joined #lisp
shrdlu68 has quit [Quit: leaving]
<Xof>
v0|d: sbcl.org was registered, if memory serves, by Kevin Rosenberg (kmr); nameservers are provided by medonline.com
<Xof>
medonline.com is currently down / inaccessible. E-mails to Kevin's addresses that I can find go unanswered. sbcl.org has client transfer prohibited
fikka has quit [Ping timeout: 256 seconds]
fikka has joined #lisp
Kaveren has joined #lisp
<jkordani>
uh oh
shka1 has joined #lisp
JuanDaugherty has joined #lisp
<JuanDaugherty>
somebody fucked up
<JuanDaugherty>
like the dolts in a chat channel on a certain lang that is supposed to be a realization of mathematics going on about what is and isn't discrete
nsrahmad has quit [Ping timeout: 260 seconds]
<JuanDaugherty>
compared to serious problems, it's practially amusement
vultyre has joined #lisp
Kundry_Wag has quit [Remote host closed the connection]
<JuanDaugherty>
when, yesterday, i discovered paxos and raft i was a lil surprised there didn seem to be a cl or scheme implementation
<JuanDaugherty>
multiple clojure
<JuanDaugherty>
i'm a diligent search would turn up something
<JuanDaugherty>
*i'm sure
Kundry_Wag has joined #lisp
<JuanDaugherty>
(actually pretty sure i just forgot paxos but raft was new)
<JuanDaugherty>
ofc github sbcl is unimpaired
pagnol has joined #lisp
<jackdaniel>
↑ none of this makes sense to me
<beach>
That makes two of us.
karstensrage has quit [Ping timeout: 276 seconds]
sjl has joined #lisp
<JuanDaugherty>
good
biopandemic has quit [Quit: Quit.]
sailor_cat has quit [Remote host closed the connection]
karstensrage has joined #lisp
karstensrage is now known as Guest10120
biopandemic has joined #lisp
Kundry_Wag_ has joined #lisp
<shka1>
hello
<shka1>
JuanDaugherty: feel free to implement paxos
<shka1>
it melt brains :P
<JuanDaugherty>
shka1, ty. I decided, should i need to, using a c/c++ implementation would be the way. There's a header only one.
<JuanDaugherty>
lamports story of paxos is pretty accessible
<JuanDaugherty>
(header only on raft)
Fare has quit [Ping timeout: 240 seconds]
lumm has joined #lisp
no-good-name-yet has joined #lisp
Fare has joined #lisp
fikka has quit [Ping timeout: 256 seconds]
Josh_2 has quit [Quit: ERC (IRC client for Emacs 25.3.1)]
hhdave has quit [Ping timeout: 248 seconds]
fikka has joined #lisp
Josh_2 has joined #lisp
Oladon has joined #lisp
Josh_2 has quit [Remote host closed the connection]
Kundry_Wag_ has quit [Ping timeout: 244 seconds]
fikka has quit [Ping timeout: 240 seconds]
eminhi has quit [Remote host closed the connection]
josemanuel has joined #lisp
JuanDaugherty has quit [Quit: Exeunt]
cage_ has quit [Read error: Connection reset by peer]
saki has joined #lisp
cage_ has joined #lisp
saki has quit [Read error: Connection reset by peer]
<Bike>
oh, i thought sbcl.org was hosted by sf. sorry for spreading rumors then.
fikka has joined #lisp
m00natic has quit [Remote host closed the connection]
lumm has quit [Ping timeout: 265 seconds]
fikka has quit [Ping timeout: 256 seconds]
anewuser has joined #lisp
LiamH has joined #lisp
anewuser has quit [Ping timeout: 265 seconds]
Kundry_Wag has quit []
papachan has quit [Quit: Leaving]
cage__ has joined #lisp
cage_ has quit [Ping timeout: 264 seconds]
j0ni has joined #lisp
cage__ has quit [Client Quit]
cage__ has joined #lisp
newbie has joined #lisp
Fare has quit [Ping timeout: 240 seconds]
Xof has quit [Ping timeout: 264 seconds]
Fare has joined #lisp
fikka has joined #lisp
fikka has quit [Ping timeout: 256 seconds]
kuwze has quit [Quit: Page closed]
orivej has joined #lisp
smurfrobot has joined #lisp
smurfrobot has quit [Ping timeout: 244 seconds]
cage_ has joined #lisp
Oladon1 has joined #lisp
nika has quit [Quit: Leaving...]
Oladon has quit [Ping timeout: 244 seconds]
MoziM has quit [Quit: WeeChat 2.2]
pagnol has quit [Ping timeout: 240 seconds]
shka1 has quit [Ping timeout: 240 seconds]
sauvin has quit [Remote host closed the connection]
j0ni has quit [Remote host closed the connection]
cage_ has quit [Quit: Leaving]
kajo has joined #lisp
gehlw has joined #lisp
FreeBirdLjj has quit [Remote host closed the connection]
FreeBirdLjj has joined #lisp
Fare has quit [Ping timeout: 268 seconds]
Xof has joined #lisp
FreeBirdLjj has quit [Ping timeout: 240 seconds]
makomo has joined #lisp
makomo_ has quit [Ping timeout: 276 seconds]
Kundry_Wag has joined #lisp
jasmith has quit [Ping timeout: 260 seconds]
Oladon1 has quit [Quit: Leaving.]
eli_oat has quit [Quit: eli_oat]
eli_oat has joined #lisp
kajo has quit [Ping timeout: 256 seconds]
knusbaum has joined #lisp
EvW has joined #lisp
Kundry_Wag has quit [Ping timeout: 240 seconds]
nickenchuggets has joined #lisp
nickenchuggets has quit [Changing host]
nickenchuggets has joined #lisp
fikka has joined #lisp
fikka has quit [Ping timeout: 260 seconds]
MoziM has joined #lisp
nowhereman_ has quit [Ping timeout: 256 seconds]
smurfrobot has joined #lisp
vultyre has quit [Quit: Leaving]
smurfrobot has quit [Ping timeout: 240 seconds]
Kundry_Wag has joined #lisp
pierpal has quit [Quit: Poof]
pierpal has joined #lisp
<phoe>
It's amazing how different languages have different means of solving issues
<phoe>
......and Lisp is capable of swallowing so many of them
<dlowe>
well, this bit needs to be set to a 1, and that bit needs to be set to a 0.
<phoe>
I just realized that I started doing error handling the Erlang way, by returning a secondary value that states if a thing was successful or not
<phoe>
It took me a while to actually notice that I don't have to do that - I can signal a condition instead
pagnol has joined #lisp
eli_oat has quit [Quit: Leaving.]
EvW has quit [Ping timeout: 255 seconds]
EvW has joined #lisp
<jasom>
phoe: well the standard library does it both ways
vlatkoB has quit [Remote host closed the connection]
<dlowe>
yeah, the question is, is it something you'd want to enter the debugger for?
Kundry_Wag has quit [Ping timeout: 256 seconds]
fikka has joined #lisp
fikka has quit [Ping timeout: 240 seconds]
NoNumber has joined #lisp
pierpal has quit [Quit: Poof]
fikka has joined #lisp
pierpal has joined #lisp
fikka has quit [Ping timeout: 268 seconds]
fikka has joined #lisp
gabiruh has quit [Read error: Connection reset by peer]
gabiruh has joined #lisp
pierpa has joined #lisp
fikka has quit [Ping timeout: 264 seconds]
orivej has quit [Ping timeout: 268 seconds]
fikka has joined #lisp
karswell has quit [Remote host closed the connection]
karswell has joined #lisp
fikka has quit [Ping timeout: 256 seconds]
Cymew has joined #lisp
fikka has joined #lisp
Cymew has quit [Ping timeout: 260 seconds]
Fare has joined #lisp
Bike has quit [Ping timeout: 252 seconds]
josemanuel has quit [Quit: leaving]
Fare has quit [Ping timeout: 240 seconds]
biopandemic has quit [Quit: Quit.]
biopandemic has joined #lisp
biopandemic has quit [Client Quit]
biopandemic has joined #lisp
SaganMan has joined #lisp
Denommus has quit [Remote host closed the connection]