Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Taylor – Swift on bare metal (github.com/klange)
157 points by tambourine_man on Sept 6, 2016 | hide | past | favorite | 69 comments


I'm the author. This wasn't something anyone was supposed to 'find', it's not even really a 'project', just a quick hack to demonstrate a point; I don't even think it's valid to say the project name is "taylor", it's just the name of the repository - I probably should have just called it "swift-on-baremetal" or something equally boring. I have a history of my stupid little 'projects' showing up on HN.


Please don't let the anti-fun brigade on HN stop you.


You should be proud of your creative projects and funny names!


I dont use Swyft, so definitely have no interest in running it bare metal... but the name is brilliant. It made me click on the link. Just had to tell you that!


I'm curious as to what kind of bare metal is meant. From the “ elf_i386” target I infer it's some kind of Linux machine?


The code in the repository builds a multiboot-compatible x86 "kernel" that can be booted with GRUB or iPXE or any number of other bootloaders supporting the format.


Maybe we need a rule about submitting other people's projects? Even though I don't mind if people check out/use my public GitHub repos I would not want them submitted on HN by someone else.


A lot of the best "finds" come from finding stuff in other peoples projects that they didn't think was worth submitting. It'd be a shame to lose that.


Yeah I get that but maybe it'd be worth checking in with the repo owner before submitting it or something? I dunno. I don't see any easy solution.


If there's a reason to think there's something wildly controversial there, perhaps, but if you've put it in a public repo I really don't think that should be a requirement. Especially given that there are several places where you can repos private for free if you don't want people to give it more attention than you planned.


The submitter seems to be a spammer for submitting stories to HN that don't generate much utility.


I should clarify that I'm not insulting the linked projects; I'm pointing out the limited discussion and large number of submissions the submitter gives.


whatever, that is the best name I've seen for an OS project all year. Bravo.


I had thought most of us know this video presentation. Still an interesting video.

https://realm.io/news/swift-summit-jorge-izquierdo-taylor-ht...

There are a few talks on Swift in Realm conference.


Could someone please explain what this project is about? I gather it's a new implementation of the Swift language without using Xcode's compiler and Swift standard library, but I find the full readme very undescriptive of what this is and why it's useful.

EDIT: Clicking through the source I found about a dozen files in total, mostly scripts and make files.


It builds Swift without any standard library, runtime or linkage to other components. This isn't normally possible with the Swift compiler.

The solution doesn't involve changing the compiler or building everything into the executable. Instead, this is a makefile coordinated pipeline (front-end swiftc, back-end clang) plus a start.s and a system.c file that omit any need for typical standard library components in the first place.

i.e. a "bare metal" compilation


Without the swift standard library, what can be done? Doesn't the standard library include all of the basic types, like Array, Int, etc?


Fixed-size integers and UnsafeMutablePointer are supported, so it is basically C with different syntax:

https://github.com/klange/taylor/blob/master/src/main.swift


Except it has a stronger type checking and safety.


sounds good, what's the draw back like?


It's not a new implementation so much as compiling Swift for different architectures and environments not supported by the compiler.

It still uses the Swift compiler but emits LLVM IR and then uses Clang to target to the different environments.


The assembler and Makefile are x86 only. I'm not seeing support for other architectures.


It is for running Swift code without an operating system.

It could be used to write a kernel in Swift.


You can use swiftc (the Swift compiler) without Xcode just like you can use clang without Xcode. Xcode is just an IDE.


    Horrible Taylor Swift puns in Swift development 
    considered harmful. 
It's already been done[1], it makes your project completely un-Googleable, and it also pollutes the search corpus making it harder for automatons to weed out Taylor Swift stories even when searching for things like "Swift compiler intermediate representation".

Please stop!

[1]: https://github.com/izqui/Taylor


Someone slept though their humor class.

Try this -> :)


As a go player, I had the same problem when google has created the go language.


Try with baduk :)


This is a problem with Google, not with the names.


That doesn't really seem likely, since it's also a problem with every single other automated search engine in the world.

Names are important; names are famously hard[1].

When I was young, I was a member of a band named Fuck You Asshole. Was that a problem with conversation, not with the band name?

[1]: https://twitter.com/codinghorror/status/506010907021828096


It's a problem of recognising context. Current technology is not very good at this. What would be nice to have is automatic disambiguation - taking fdej's example, when searching for "Taylor shift", a search engine could ask "Did you mean Taylor Swift, or do you want to shift polynomials?".

Other possible examples: "bat" (flying animals or sports equipment?), "rock" (stones, music, or maybe both? :P), "minute" (60 seconds, report, or something extremely small?). In all of these cases, the software can't tell the meanings apart very well yet. That's a problem with the software.


duckduckgo does exactly that - it lists all the possible interpretations across the top of the results page, plus a list of likely matches (based on statistics I suppose). Try searching for 'polish' which could mean making shoes shiny, or central European people.


No deliberate puns required. As a computer algebraist, it bothers me that "Taylor shift" is un-Googleable.


Why stop? Maybe it is google that should implement something like ':technology' area searches.



    Lack of humour considered harmful.


maybe un-Googleable but social-mediable as the pun increases visibility when the sharing and voting mechanism is involved.


So it's like a captcha for index/retrieval, interesting. A purely cultural robots.txt reimplementation that extends the index invisibility cloak even to mentions on third party sites!


"What's in here right now doesn't need any Swift runtime support. That will change very quickly as we try to add support for things like arrays, classes, structs, strings, etc."


Didn't get the point of using inline assembly for outportb instead of making it part of start.s.

Just to prove the point of calling something with C calling convention?


Yes.


Ah ok


Cool! but you have a name collision: https://github.com/izqui/Taylor


Name collisions aren't uncommon, of course it's courteous to try avoid them. But, from the page you linked:

> Disclaimer: Not actively working on it anymore. You can check out some alternatives


I can think of at least one other "name" collision.



I think the fun ends when most Swift related stuff are named Taylor...

Some examples are

- the OP's project

- https://tailor.sh/ - Cross-platform static analyzer and linter for Swift

- https://github.com/izqui/Taylor - lightweight library for writing HTTP web servers with Swift

- Many many others at https://github.com/search?l=Swift&q=taylor&type=Repositories...


Hahahahaha this name is amazing!


I don't normally comment like this but ..

That title bothers me a bit.


But software projects are swarmed with bad puns


I up voted this post just because of the name. Very clever. Kudos.


where is seed?


Taylor Swift metal is oxymoron.


upvote for the name alone


don't be surprised if people can't find your project with a name like that.


It was hard enough when Swift 1.0 was released and Google searches kept bringing up this woman, this will be worse.


Nothing hard about appending "lang" to your queries. Go and C programmers have to deal with the same thing.


Yeah, long ago I learned the difference between "strings in C" and "C strings" when searching Google.


The Google personalisation filter bubble seems to have me covered, even in incognito (this is a work machine with its own public IPv4). Nothing but programming on the first five pages for either query.

"std list" is another good one, with very different meanings to C++ programmers and just about anyone else :)


Singular does the trick.


ahahahahahaha


Because Google had to choose a hard to google language name fot its language... :)


Well, the clang compiler might interfere with that nowadays, even though it's a C compiler.


Try that right now with both names and 'lang' appended.


Does anyone see the awesomeness of the title of this post?

Taylor Swift.

Ha.


you catch on quick


Bad project name for SEO purposes. Do you really want people to trudge through SERPs of some popstar who makes vapid music before they get to your project?


Nice elitism 10/10 I like that you called the project name bad AND insulted a talented performer, well done.


The whole story is in this video, nothing related to SEO or whatever. https://realm.io/news/swift-summit-jorge-izquierdo-taylor-ht...




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: