Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perf: compiler performance optimization #9674

Merged
merged 56 commits into from
Nov 25, 2023
Merged

perf: compiler performance optimization #9674

merged 56 commits into from
Nov 25, 2023

Commits on Nov 21, 2023

  1. wip: setup

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    21d322b View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    e610fdb View commit details
    Browse the repository at this point in the history
  3. wip: remove unused options

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    ea08664 View commit details
    Browse the repository at this point in the history
  4. wip: port parser

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    16942a2 View commit details
    Browse the repository at this point in the history
  5. wip: save

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    081ca7e View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    4529f9b View commit details
    Browse the repository at this point in the history
  7. wip: loc for elements

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    23448e0 View commit details
    Browse the repository at this point in the history
  8. wip: parse directives

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    cb38786 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    2fbef69 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    a8feccd View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    73373b9 View commit details
    Browse the repository at this point in the history
  12. wip: modifiers

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    fd50689 View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    49db157 View commit details
    Browse the repository at this point in the history
  14. wip: remove htmlMode

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    4306249 View commit details
    Browse the repository at this point in the history
  15. Configuration menu
    Copy the full SHA
    dd02806 View commit details
    Browse the repository at this point in the history
  16. wip: parse interpolation

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    90a4db9 View commit details
    Browse the repository at this point in the history
  17. wip: pre tag handling

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    9d189bf View commit details
    Browse the repository at this point in the history
  18. wip: v-pre handling

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    e1aaf97 View commit details
    Browse the repository at this point in the history
  19. wip: refine element type

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    08f5826 View commit details
    Browse the repository at this point in the history
  20. wip: comments

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    a28c650 View commit details
    Browse the repository at this point in the history
  21. Configuration menu
    Copy the full SHA
    a870aaf View commit details
    Browse the repository at this point in the history
  22. perf: optimize makeMap

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    ba5aa7a View commit details
    Browse the repository at this point in the history
  23. wip: parseMode

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    e54e0e1 View commit details
    Browse the repository at this point in the history
  24. Configuration menu
    Copy the full SHA
    04c0b33 View commit details
    Browse the repository at this point in the history
  25. Configuration menu
    Copy the full SHA
    d506584 View commit details
    Browse the repository at this point in the history
  26. wip: parse mode

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    1f7c0ce View commit details
    Browse the repository at this point in the history
  27. refactor: swap to new template parser

    - get rid of SourceLocation.source for memory efficiency
    - move source location generation logic transform phase into the parser
      itself so that SourceLocation.source is no longer needed
      - move v-for expression parsing into the parser itself
      - added nameLoc on AttributeNode for use in transformElement
    
    Tests are not passing yet.
    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    956beba View commit details
    Browse the repository at this point in the history
  28. Configuration menu
    Copy the full SHA
    b7b310b View commit details
    Browse the repository at this point in the history
  29. wip: more tests passing

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    eadf6f8 View commit details
    Browse the repository at this point in the history
  30. Configuration menu
    Copy the full SHA
    a52b5f0 View commit details
    Browse the repository at this point in the history
  31. wip: tune perf

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    973de35 View commit details
    Browse the repository at this point in the history
  32. Configuration menu
    Copy the full SHA
    1021e33 View commit details
    Browse the repository at this point in the history
  33. Configuration menu
    Copy the full SHA
    47224c6 View commit details
    Browse the repository at this point in the history
  34. Configuration menu
    Copy the full SHA
    10f7d10 View commit details
    Browse the repository at this point in the history
  35. Configuration menu
    Copy the full SHA
    1aec019 View commit details
    Browse the repository at this point in the history
  36. Configuration menu
    Copy the full SHA
    13032e8 View commit details
    Browse the repository at this point in the history
  37. Configuration menu
    Copy the full SHA
    65831e7 View commit details
    Browse the repository at this point in the history
  38. wip: decodeEntities test

    yyx990803 committed Nov 21, 2023
    Configuration menu
    Copy the full SHA
    cc90ee0 View commit details
    Browse the repository at this point in the history
  39. Configuration menu
    Copy the full SHA
    6ea6477 View commit details
    Browse the repository at this point in the history
  40. Configuration menu
    Copy the full SHA
    c88fa63 View commit details
    Browse the repository at this point in the history
  41. Configuration menu
    Copy the full SHA
    4c78df0 View commit details
    Browse the repository at this point in the history
  42. Configuration menu
    Copy the full SHA
    02e0205 View commit details
    Browse the repository at this point in the history
  43. Configuration menu
    Copy the full SHA
    63d92ff View commit details
    Browse the repository at this point in the history
  44. Configuration menu
    Copy the full SHA
    94d1cf4 View commit details
    Browse the repository at this point in the history
  45. Configuration menu
    Copy the full SHA
    8f13ee6 View commit details
    Browse the repository at this point in the history
  46. Configuration menu
    Copy the full SHA
    66f0d0d View commit details
    Browse the repository at this point in the history

Commits on Nov 22, 2023

  1. wip: parse error tests

    yyx990803 committed Nov 22, 2023
    Configuration menu
    Copy the full SHA
    d29e8b5 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    a3c1a08 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    bf95cf2 View commit details
    Browse the repository at this point in the history
  4. wip: parser v2 compat

    yyx990803 committed Nov 22, 2023
    Configuration menu
    Copy the full SHA
    7bdde97 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    8c87718 View commit details
    Browse the repository at this point in the history

Commits on Nov 23, 2023

  1. Configuration menu
    Copy the full SHA
    d5c03b1 View commit details
    Browse the repository at this point in the history
  2. perf(compiler-sfc): remove magic-string trim on script

    magic-string's trim method uses a regex check for aborting which turns
    out to be extremely expensive - it cna take up to 10% time in total SFC
    compilation! The usage here is purely aesthetic so simply removing it
    for a big perf gain is well worth it.
    yyx990803 committed Nov 23, 2023
    Configuration menu
    Copy the full SHA
    c7a3d54 View commit details
    Browse the repository at this point in the history
  3. perf(codegen): optimize line / column calculation during codegen

    Previously, many CodegenContext.push() calls were unnecessarily
    iterating through the entire pushed string to find newlines, when we
    already know the newline positions for most of calls. Providing fast
    paths for these calls significantly improves codegen performance when
    source map is needed.
    
    In benchmarks, this PR improves full SFC compilation performance by ~6%.
    yyx990803 committed Nov 23, 2023
    Configuration menu
    Copy the full SHA
    a95d76e View commit details
    Browse the repository at this point in the history

Commits on Nov 24, 2023

  1. Configuration menu
    Copy the full SHA
    8928473 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    7b0cc28 View commit details
    Browse the repository at this point in the history