Opened 9 months ago

Closed 9 months ago

Last modified 8 months ago

#22572 closed enhancement (fixed)

libfyaml-0.9.2

Reported by: Bruce Dubbs Owned by: Douglas R. Reno
Priority: normal Milestone: 13.0
Component: BOOK Version: git
Severity: medium Keywords:
Cc:

Description

New point version.

Change History (9)

comment:1 by Xi Ruoyao, 9 months ago

I cannot get it build: ​https://github.com/pantoniou/libfyaml/issues/156

Maybe a workaround is building w/o --disable-static but instead removing the .a file after installation.

comment:2 by Bruce Dubbs, 9 months ago

Building without --disable-static works fine. I think we should just:

rm -fv /usr/lib/libfyaml.{a,la}

after install.

comment:3 by Bruce Dubbs, 9 months ago

libfyaml v0.9.1

This is libfyaml v0.9.1, a significant maintenance release focused on licensing clarity, performance, stability, and build system modernization. Critical: Now Fully MIT Licensed

This release removes all GPL-licensed code from libfyaml. The previous GPL list implementation has been replaced with a clean-room MIT-licensed version. The entire library is now consistently MIT licensed without any GPL components, making it suitable for use in commercial and proprietary projects without any licensing concerns.

Performance Highlights

  • Up to 24x faster on large files: fy-tool now uses streaming mode by default (105MB file: 18.3s → 0.776s)
  • 2x faster emission through optimized plain scalar token analysis
  • Thread-safe lockless allocators for multi-threaded applications
  • Significantly improved UTF-8 handling and parsing performance

Stability Improvements

Fixed 12 critical bugs including:

  • Segmentation faults and memory corruption issues
  • Use-after-free errors in document processing
  • Crashes on malformed input

New Features

Allocator Infrastructure

  • Thread-safe lockless allocators (linear, malloc, mremap, dedup, auto)
  • New fy_allocator_contains() API for pointer containment checks
  • In-place allocator support (no malloc required)

Parser & API Enhancements

  • Parser checkpointing: fy_parser_parse_peek(), fy_parser_skip(), fy_parser_count_*() for look-ahead operations
  • Composer interface: Public event-based document composition API
  • Document builder: Public API for programmatic document construction
  • YPath operators: @ for set inclusion, ! for set exclusion
  • New node operations: fy_node_delete(), fy_emit_body_node()
  • Tag utilities: fy_node_get_tag0(), fy_node_get_tag_length()
  • Event reporting: fy_event_report() methods for diagnostics

Build System Modernization

  • CMake now at feature parity with autotools
  • Full cross-compilation support (both CMake and autotools)
  • Optional libclang integration for type-aware features
  • Documentation build targets: doc-html, doc-latexpdf, doc-man
  • New --enable-static-tools configuration option

Breaking Changes

Minor API Change

  • Added minimum_bucket_occupancy field to dedup allocator configuration structure (no known external users affected)

Behavioral Change

  • fy-tool now defaults to streaming mode for dump operations (24x faster)
  • Streaming mode loses ability to reference forward anchors and perform strict duplicate key checking
  • Use --no-streaming flag to restore previous document mode behavior

What's Changed

Added

  • Thread-safe lockless allocator infrastructure
  • Parser checkpointing and look-ahead APIs
  • Public composer and document builder interfaces
  • YPath set operators and enhanced path operations
  • Compact emitter formats (flow and JSON)
  • Cross-compilation support
  • examples/ directory with library usage examples
  • Comprehensive allocator and parser tests

Changed

  • fy-tool uses streaming mode by default (up to 24x faster)
  • Emission performance improved up to 2x
  • UTF-8 handling significantly faster
  • CMake build system at feature parity with autotools
  • Stream YAML version handling now per-stream
  • Improved block scalar handling

Fixed

  • Segmentation fault in fy_reader_* when all input processed
  • Use-after-free when document acceleration fails
  • Double-free in fy_node_setup_path_expr_data
  • Use-after-free after document resolution
  • Crash when assertions compiled out in release mode
  • Crash when addressing expression incorrectly
  • Crash on error during walk evaluation
  • Segmentation fault on garbage input
  • Segmentation fault when block scalar indicators last in input
  • Assertion preventing node deletion
  • Crash when comparing mappings with NULL values
  • Portability crash on NEC Aurora (enums in bitfields)
  • Infinite loop in scan directive for malformed UTF-8
  • Multiple use-after-free and memory corruption issues
  • MacOS compatibility issues
  • Numerous compiler warnings at high optimization levels

Documentation & Examples

  • New examples/ directory with usage samples
  • Fixed all documentation build errors
  • Updated API reference
  • New CHANGELOG.md following Keep a Changelog format

comment:4 by zeckma, 9 months ago

Owner: changed from blfs-book to zeckma
Status: new → assigned

comment:5 by Xi Ruoyao, 9 months ago

Summary: libfyaml-0.9.1 → libfyaml-0.9.2

Now 0.9.2 with the build failure fixed.

comment:6 by zeckma, 9 months ago

Owner: changed from zeckma to blfs-book
Status: assigned → new

Pretty sure I have COVID Nimbus right now and Doug asked that I rest at least till Friday, so I'm reassigning this ticket to blfs-book.

comment:7 by Douglas R. Reno, 9 months ago

Owner: changed from blfs-book to Douglas R. Reno
Status: new → assigned

comment:8 by Douglas R. Reno, 9 months ago

Resolution: → fixed
Status: assigned → closed

Fixed at 2df0d5096448f3ad501a9d8cec7b941ffd2d0656

Documented a test failure in AppStream at f794a7f030c734bbcf766e439f6bbeca5e89b1fd

comment:9 by Bruce Dubbs, 8 months ago

Milestone: 12.5 → 13.0

Milestone renamed

Note: See TracTickets for help on using tickets.