Skip to content

Efficient List append and prepend #43

@tmarsteel

Description

@tmarsteel

The current Implementation of append/3 uses O(n) time and copies the entire list. In pure propog, there is no other way, but this performance is not acceptable.

  • append/3 should be replaces with a native version that does these goals in O(1) memory and time:
    • append(+List, +List, _)
    • append(-List, +List, +List)
    • append(+List, -List, +List)

Metadata

Metadata

Assignees

No one assigned

    Labels

    mem-optimizationOptimizes memory footprintperf-optimizationOptimizes execution speed of prolog codestdlibStandard Library

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions