1.  

    no need to write(), just mmap() the output file too and even use MADV_DONTNEED.

    1.  

      For those that enjoy HyperCard there is another xtalk language that is still in development that is awesome. It is called LiveCode (but it was known as Runtime Revolution and is based on what was MetaCard). There is both a commercial version at https://www.livecode.com and a GPL version at https://www.livecode.org. I’ve worked with it for the past ~20 years, so feel free to ask me anything. LiveCode runs under Windows, macOS, Linux and compiles for all those platforms plus iOS and Android. So it is a modern cross-platform descendant of HyperCard.

      1.  

        Xtensa’s are CPU’s that are custom made for specific applications with toolchain and such generated from what I read. It appears easy to incorporate them into SoC designs, too. Might be why ESP8266 uses something like that. Tensilica’s is very interesting tech that you might find anywhere with a custom need. :)

        1.  

          One can only wonder how the microprocessor space would look today, if Intel and AMD had played by the same rule book.

          They sort of did, though. They both offered complex ISA’s that sacrificed security and reliability for performance optimizations. The companies that offered the former either went bankrupt or had to ditch hardware-level security. The Itanium, which had security enhancements, was a recent example of a massive loss for trying to do something different. The market has been very clear that they don’t give a shit about security: just backward compatibility and performance that goes up every 18 months or so. Any company that did anything else suffered greatly.

          Now, people are worried about CPU security. Yet, I’m still not sure they’ll sacrifice backward compatibility and/or lots of performance upfront if a new CPU advertised that. Instead, Intel and AMD are selling people on both of those being good while apologizing about effects of patches later on after purchase. Works better with market psychology. Intel apparently doing worse but AMD’s processors aren’t secure either.

          1.  

            I thought codata was related to corecursion, in fact serving a similar purpose to Python generators. My notion of codata comes from the Idris construct of that name:

            codata Stream : Type -> Type where
              (::) : (e : a) -> Stream a -> Stream a
            

            This gets translated into the following by the compiler.

            data Stream : Type -> Type where
              (::) : (e : a) -> Inf (Stream a) -> Stream a
            

            This is similar to what Wikipedia has to say:

            Coinductively defined types are known as codata and are typically infinite data structures, such as streams.

            Are these two separate notions with the same name or am I missing a connection here? Granted I kind of skimmed both texts.

            1.  

              Worth keeping as another example of how aspects of our systems are just historical baggage tied to arbitrary decisions or problems that don’t exist any more. Like bin vs sbin on UNIX. Microsoft’s Windows has its own baggage it can’t slash going forward.

              1.  

                “I know most/many OSS licenses sort of wimp out on patents and ignore the problem, CDDL doesn’t.”

                That would be re-assuring on patent part.

                “Possible sure, but it would be possible for any other crazy lawyer to go nuts here (wholly unrelated to ZFS or even technology), it’s not an Oracle exclusive idiocy. Trying to avoid unknown lawyering”

                Oracle was the only one to flip software copyright on its head like this. So, I don’t think it’s an any company thing. Either way, the threat I’m defending against isn’t unknown lawyering in general: it’s unknown lawyering of a malicious company whose private property I may or may not depend on. When you frame it that way, one might wonder why anyone would depend on a malicious company at all. Avoiding that is a good pattern in general. Then, the license negates some amount of that potential malice for a great product with unknown, residual risk.

                I agree the residual risk probably won’t affect individuals, though. An Oracle-driven risk might affect small to mid-sized businesses depending on how it plays out. Good news is swapping filesystems isn’t very hard on Linux and BSD’s. ;)

                1.  

                  One could also make the argument every processor vendor has been playing fast and loose for decades by allowing memory accesses to unexpected locations, resulting in countless exploited systems. Other suggested hardware designs mitigate that, in hardware 1. However neither AMD nor Intel have taken it upon themselves to integrate such work due to the resulting performance overhead. My point is it’s all relative, and we should not be so quick to point fingers and decry industry-wide accepted practices like data forwarding. Instead it’s more productive to reflect on the current art in security and have a nuanced discussion on how we can do better.

                  For example, would the community prefer locking down the entire processor, or is it better to have secure co-processors and leave it up to the programmer to decide what data is dangerous to leak, and what data we don’t care about it? This could also be seen as an opportunity for innovations in the hardware design space, where cloud, workstation, mobile, and IoT processors all see an increase in heterogeneity to support their respective threat vectors.

                  1.  

                    They’re quite explicit that users are supposed to retheme them as they please (just not cry over anything that breaks due to that). However it’s not very userfriendly for distros to ship applications broken by default just to make them try to fit in some one-size-fits-all theme.

                    1.  

                      Worth watching. Key ideas:

                      • OOP model is “interacting agents” managing mutable state.
                      • FP model is an input->output pipeline.
                      • To avoid mutable state and other side-effects:
                        1. minimize: avoid/eliminate where possible
                        2. concentrate: keep it in a central place
                        3. defer: queue operations to the last step or an external system
                      1.  

                        You could also use CHAR_BIT * sizeof(unsigned int) to get the number of bits in an unsigned integer (which is better suited for this type of job). Both are constants, so there should be no runtime overhead for calculating that result. I would also be inclined to make the functions static inline (a C99 feature) and define them in a header. That avoids any issues with macros while still producing decent code. Something like:

                        #include <limits.h>
                        #include <stdlib.h>
                        
                        static inline void setbit(unsigned int *a,size_t size,size_t idx)
                        {
                          size_t       off = idx / (CHAR_BIT * sizeof(unsigned int));
                          unsigned int bit = idx % (CHAR_BIT * sizeof(unsigned int));
                          unsigned int val = 1u << bit;
                        
                          if (off >= size) abort();
                        
                          a[off] |= val;
                        }
                        
                        1.  

                          Oh I was already excited by this and hadn’t even noticed the space bar, great to see.

                          1.  

                            Hi vladislavp,

                            Thanks for your questions. Yes you can self host Peergos and then your instance will be responsible for storing all your data. When you sign up you communicate with a global pki to claim your username. We chose the UX tradeoff there because that’s what people are used to.

                            Currently there isn’t any guaranteed caching (though if someone else views your file, ipfs should cache it on their instance temporarily. Longer term we hope to let you mirror your stuff on your friend’s nodes.

                            Only people who you grant access (read or write) to a file can see it. You can also create a public link to a file which anyone can use to view it, without needing to install or sign up to anything, e.g.: https://demo.peergos.net/#6MDZhRRPT4ugkJuUfcPPhf1US9u7FvRALmj42mJ6e3yDibnLtqfhchE6Frm6Lf/6MDZhRRPT4ugkJuUfcZdxu6JLKyrLBE36Kasxb4jix7An4dbeiekpDF6h2fDBM/HUja6zmXVs24zcRf15s1MWB7kfvyTCp2X9NF4EZqcw7/5Pf7SvCKyBYfP1vm5LfTSw8TMHtLWvJDLv1P4QtCXV8P2Zv8FwR

                            You can delete your files yes. That was a core requirement. It should behave like a global filesystem.

                            At the moment the social side is quite primitive, you can share files and folders (read only, or writable) with other peergos users who follow you (and revoke said access, which means rotating keys and re-encrypting). We plan to add many-to-many messaging ala Signal, and later a more traditional social feed as well. The whole thing is independent of DNS or the TLS certificate authorities (unless you choose to use a public web interface) so there’s no need to get a domain name and manage all that complexity if you want to run your own instance. (You can access your instance from elsewhere still without DNS or TLD using ipfs’s p2p streams which are E2E encrypted independently).

                            1.  

                              I keep hoping that GraalVM gets easier to package. Cool tech but so annoying to get on non standard systems.

                              1.  

                                I fondly remember HyperCard as enabling anyone to create interactive content and functionality, in a free, simple, approachable, use-it-as-you-play way.

                                It allowed non-programmers of all ages to be creators. We are arguably much more a world of online consumers today, serviced by inaccessible (to many) technologies, languages and deployment models. Is there no place for such creativity tools today?

                                1.  

                                  While the examples convey the idea, there are a number of issues with using them for teaching C. For instance:

                                  • The macros are missing parenthesis around the macro parameters. SetBit(A, i + 1) will not expand to what you want
                                  • There is no range checking
                                  • It assumes that int is 32-bit. The standard only specifies a minimum range for int which is 16 bits. You likely want to use one of the fixed-width integer types from C99 like uint32_t.
                                  • Signed integers do not necessarily allow you to use all possible bit patterns. Signed int might not be two’s complement, and there could be values that are trap representations (I know this is entering the realm of the unlikely, but if you want portable C you have consider this).
                                  1.  

                                    Planning for me isn’t about “being productive”, it’s about using my time intentionally.

                                    Any planning has an initial intention. The point I tried to convey above was that you may not yourself be aware of the best life for your own self. You may think you are directing it in the direction you want, creating a narrow nifty path, but that may not be the case. I wholeheartedly sing with you the chant that we’re not production machines of our own lives.

                                    I agree with you on the second paragraph, you shouldn’t be your own tyrant. I guess that the situation I was in and the conclusion are only applicable to persons who went through an extreme planning phase to then resurface and embrace the possibilities that chaos can give. It certainly doesn’t match well with professional procrastinators, technology/media addicts, and the ones that are directionally challenged about their lives.

                                    Thanks for the comment.

                                    1.  

                                      Way back in the day, so many important/interesting people in the web design and dev world used MT that it still biases my reaction to sites that obviously run MT today, or use a theme based on the old MT default.

                                      1.  

                                        In its two decade life span, HyperCard was enormously successful, and it succeeded all over the world. The Victoria Museum of Melbourne, which keeps track of Australia’s scientific and cultural history, has published a list of ways that educators in Melbourne used the program:

                                        Today’s Internet has failed to engage educators the way HyperCard did. My wife is a teacher, and I used to work for a school district. We are still in the dark ages of computing.

                                        1.  

                                          I think we have a variation on this theme in illumos: https://github.com/illumos/illumos-gate/blob/master/usr/src/uts/common/os/bitset.c