WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Webkit notes  (Read 19978 times)

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11048
Webkit notes
« on: June 09, 2014, 05:33:55 AM »
Lately I've been looking into what it would take to have a FLTK port of Webkit.
One thing's become quite clear, a light browser it wouldn't be :p

Webkit parts:
WTF adds ~1mb.
JavascriptCore adds ~11mb. This is with LLVM/FTL disabled.
WebCore adds ~40mb. WebGL, audio, video disabled.
Webkit2 is estimated at ~7mb.
Actual app code estimated at pithy few hundred kb.

Static deps:
libgcc + libstdc++ add ~7mb. These are static because webkit requires rather recent gcc.
ICU adds ~25mb. Static for two reasons: one, it's a few mb smaller than
dynamically; secondly, it's a C++ lib. Having it dynamic would cause galaxies to explode the
first time it threw an exception, as it would bring in the system libstdc++.
Harfbuzz adds ~1mb. Same reasons as ICU.

All stripped binary numbers.

So the binary is already closing in on 100mb! That's some amazing bloat. LTO and other
tricks may get 10% off that, but still quite impressive numbers for a "light" build. LLVM
for example would easily add 50mb.

What would it save, then? Compared to the Qt port, Qt of course, a 140mb+ monster. But to
the other ports of efl and gtk? Perhaps a couple mb and some annoying deps, nothing more.

It may still get done because I'm pissed with the current state of browsers, but it's
heavily looking like "light" is not on the list of features...
The only barriers that can stop you are the ones you create yourself.

Offline Lee

  • Hero Member
  • *****
  • Posts: 645
    • My Core wiki user page
Re: Webkit notes
« Reply #1 on: June 09, 2014, 09:46:30 AM »
Quote
It may still get done because I'm pissed with the current state of browsers...

I'm curious as to what facet of the current state of browsers you find worst and what might be done about it.  The reason I ask is that I'm looking at installing the latest and greatest Firefox to help the company web developer test an application.  This is on Windows, but eventually somebody will have to test it on a linux platform.

Right now, I much prefer to stay -way- behind the bleeding edge of browser technology because of what I perceive as "the current state of browsers".
32 bit core4.7.7, Xprogs, Xorg-7.6, wbar, jwm  |  - Testing -
PPR, data persistence through filetool.sh          |  32 bit core 8.0 alpha 1
USB Flash drive, one partition, ext2, grub4dos  | Otherwise similar

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14828
Re: Webkit notes
« Reply #2 on: June 09, 2014, 09:49:21 AM »
Whilst webkit is no doubt huge, some of the deps are shared with other gtk stuff, so perhaps the delta bloat is not as bad as you might think (as long as you use other gtk stuff) - I've been using epiphany and webkit for a while for this reason.

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11048
Re: Webkit notes
« Reply #3 on: June 09, 2014, 10:50:56 AM »
@Juanito

Yes, cairo and glib are shared in all cases, as well as some other dynamic deps. I only listed static ones. Of course if you have multiple webkitgtk browsers, then webkit is shared between them.

@Lee

In general, I find the movement to "apps on the web" completely wrong. Javascript is being used for things it has no place in, to the detriment of both developers and users. It is terrible to code in due to many reasons, speaking from experience; badly coded JS hogs cpu like no other, also from experience. Compatibility across browsers is fairly bad, and if one of the big frameworks drops support for the one you use, half the internet breaks.

I also think GL, CL, audio and video do not belong in the browser. Surely integration and games-at-work are nice, but I find that an abuse of the original purpose, sharing information. Games and calculations need native performance, having them shoehorned to the browser just opens up a huge attack surface. The moment WebCL becomes widespread you will see ads that mine bitcoin, throwing users' electricity use up, and that's one of the least malicious uses.

More to the current state, I'm sad of the direction Opera went. Chrome has multiple design choices and default options set such that it collects a lot of data off you, essentially spies on you. It's commonly countered with "you can disable each in the options", but I find it obvious that their being enabled by default conveys quite enough of Google's intent. Further, using Chrome would be like using Facebook: each new update may bring new options, of course set by default to share your information. Whack-a-mole.

Firefox has a bad UI in my opinion, and worse, they keep changing it every few versions. Mozilla has also made a few questionable decisions, such as removing options from the users, and the recent acceptance of DRM.

As the big three are close to unusable, the smaller competitors lack much compatibility (dillo, etc) or features (smaller webkit browsers), what's one to do? Can't exactly keep on using the last workable Opera to eternity.
The only barriers that can stop you are the ones you create yourself.

Offline hiro

  • Hero Member
  • *****
  • Posts: 1229
Re: Webkit notes
« Reply #4 on: June 09, 2014, 12:16:26 PM »
I'm also mad as hell.

But in a twisted way I got to be quite happy about the state of the web lately, it's getting more and more common to get a separation of content and bullshit.
I used to disable javascript selectively on the sites that were using it too much and most of all in the most wrong ways that let my fan go crazy. The term "shit hit the fan" had never felt so justified before.
Nowadays disabling javascript often just gives you a white page, but if you also disable CSS, you still get all the content, haha. I was amazed when I first realised.

The worst is if you have both javascript and CSS enabled. Modern computer "artists" want you to scroll horizontally and click around through mazes like in a first-person shooter. The javascript in no case gets used to do something useful, like to cache the next image in  full resolution. No, in most cases it will be used to *hide* all, but one image - actually a scaled-down version, and then I can click it and wait for the frame to load and for the lightbox and the shading effect and.... at least that long fade-in effect gave me enough time to realize I must have js enabled once again. Voila, the images are displayed in full width of my monitor, I can scroll down to see every single one of them, and I can even right-click and download one of them, because there's no javascript trying to tell me: "no, that's illegal, you can't steal this image".

What's the last workable opera for you, 12.14?
Did you look at surf? The people around that project also had a small discussion lately about what to do once webkit-1 is not enough any more.

Did you decide against using gecko as a backend for a fltk thingy?

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11048
Re: Webkit notes
« Reply #5 on: June 10, 2014, 04:33:03 AM »
9.64 actually (!!). The great Qt purge in 10.5 to 11.something broke a lot of things, 12 is visibly slower in common things like opening and closing tabs.

Surf: I think I read that ML discussion. The one that ended up "requires a rewrite, not going to happen unless someone does the work"?

Gecko: I didn't look deeper than the official warnings that you shouldn't embed Gecko anymore, it's not really supported that way.
The only barriers that can stop you are the ones you create yourself.

Offline bmarkus

  • Administrator
  • Hero Member
  • *****
  • Posts: 7183
    • My Community Forum
Re: Webkit notes
« Reply #6 on: June 10, 2014, 04:42:19 AM »
I found NetSurf a usable browser for ordinary tasks, reading WEB pages and not playing games, watching video, etc. Rendering is good and it is not based on 3rd-party web engines. It is what I'm using on piCore.

http://www.netsurf-browser.org/
Béla
Ham Radio callsign: HA5DI

"Amateur Radio: The First Technology-Based Social Network."

Offline hiro

  • Hero Member
  • *****
  • Posts: 1229
Re: Webkit notes
« Reply #7 on: June 10, 2014, 09:32:52 AM »
9.64 actually (!!). The great Qt purge in 10.5 to 11.something broke a lot of things, 12 is visibly slower in common things like opening and closing tabs.

Setting "Dialog Toolkit" to 4 , disabling special effects and UI animations in opera:config fixes all issues for me. I think it disables some aspects of QT.

Quote
Surf: I think I read that ML discussion. The one that ended up "requires a rewrite, not going to happen unless someone does the work"?

Yes, apparently Webkit-1 is good enough for them. And yes, the mailinglist has gotten into a really strange tone lately. You need a good anti-virus for your brain there.

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11048
Re: Webkit notes
« Reply #8 on: June 10, 2014, 12:04:40 PM »
4 is the X11 mode which I was using in my tests, unfortunately - the qt and gtk modes were even slower.
The only barriers that can stop you are the ones you create yourself.

Offline hiro

  • Hero Member
  • *****
  • Posts: 1229
Re: Webkit notes
« Reply #9 on: June 10, 2014, 06:14:28 PM »
This leaves me wondering whether this is still about configuration. Or is my core 2 duo just too fast?

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11048
Re: Webkit notes
« Reply #10 on: June 11, 2014, 02:48:39 PM »
Probably not, given I have a Phenom X6. It was just worse software.
The only barriers that can stop you are the ones you create yourself.

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11048
Re: Webkit notes
« Reply #11 on: June 12, 2014, 05:57:01 PM »
It took me ten days to get a dancing Google logo, over a SSL connection. Not sure if that's good or bad. (nothing else works yet)

The only barriers that can stop you are the ones you create yourself.

Offline Lee

  • Hero Member
  • *****
  • Posts: 645
    • My Core wiki user page
Re: Webkit notes
« Reply #12 on: June 12, 2014, 09:01:14 PM »
Whoa.  That is some seriously poor bandwidth.     :D
32 bit core4.7.7, Xprogs, Xorg-7.6, wbar, jwm  |  - Testing -
PPR, data persistence through filetool.sh          |  32 bit core 8.0 alpha 1
USB Flash drive, one partition, ext2, grub4dos  | Otherwise similar

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11048
Re: Webkit notes
« Reply #13 on: June 18, 2014, 05:13:07 PM »
73mb binary, widget passthrough in progress. It'll be ready sometime in 2018 at this rate.

« Last Edit: June 18, 2014, 05:15:33 PM by curaga »
The only barriers that can stop you are the ones you create yourself.

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11048
Re: Webkit notes
« Reply #14 on: July 09, 2014, 12:16:58 PM »
3 weeks of webkit porting + 2.5 weeks of browser-side things, and it looks like this:



One compiler bug, few hundred features, and two weeks of testing on top before a public alpha.
The only barriers that can stop you are the ones you create yourself.