mirror of
https://github.com/luau-lang/luau.git
synced 2024-12-13 05:20:38 +00:00
d458d240cd
* Definition files can now ascribe indexers to class types. (https://github.com/Roblox/luau/pull/949) * Remove --compile support from the REPL. You can just use luau-compile instead. * When an exception is thrown during parallel typechecking (usually an ICE), we now gracefully stop typechecking and drain active workers before rethrowing the exception. New solver * Include more source location information when we hit an internal compiler error * Improve the logic that simplifies intersections of tables JIT * Save testable type annotations to bytecode * Improve block placement for linearized blocks * Add support for lea reg, [rip+offset] for labels * Unify X64 and A64 codegen for RETURN * Outline interrupt handlers for X64 * Remove global rArgN in favor of build.abi * Change A64 INTERRUPT lowering to match X64 --------- Co-authored-by: Arseny Kapoulkine <arseny.kapoulkine@gmail.com> Co-authored-by: Vyacheslav Egorov <vegorov@roblox.com>
47 lines
1.4 KiB
C++
47 lines
1.4 KiB
C++
// This file is part of the Luau programming language and is licensed under MIT License; see LICENSE.txt for details
|
|
#pragma once
|
|
|
|
#include "Luau/IrData.h"
|
|
|
|
#include <string>
|
|
#include <vector>
|
|
|
|
namespace Luau
|
|
{
|
|
namespace CodeGen
|
|
{
|
|
|
|
struct CfgInfo;
|
|
|
|
const char* getCmdName(IrCmd cmd);
|
|
const char* getBlockKindName(IrBlockKind kind);
|
|
|
|
struct IrToStringContext
|
|
{
|
|
std::string& result;
|
|
const std::vector<IrBlock>& blocks;
|
|
const std::vector<IrConst>& constants;
|
|
const CfgInfo& cfg;
|
|
};
|
|
|
|
void toString(IrToStringContext& ctx, const IrInst& inst, uint32_t index);
|
|
void toString(IrToStringContext& ctx, const IrBlock& block, uint32_t index); // Block title
|
|
void toString(IrToStringContext& ctx, IrOp op);
|
|
|
|
void toString(std::string& result, IrConst constant);
|
|
|
|
void toStringDetailed(IrToStringContext& ctx, const IrBlock& block, uint32_t blockIdx, const IrInst& inst, uint32_t instIdx, bool includeUseInfo);
|
|
void toStringDetailed(IrToStringContext& ctx, const IrBlock& block, uint32_t index, bool includeUseInfo); // Block title
|
|
|
|
std::string toString(const IrFunction& function, bool includeUseInfo);
|
|
|
|
std::string dump(const IrFunction& function);
|
|
|
|
std::string toDot(const IrFunction& function, bool includeInst);
|
|
std::string toDotCfg(const IrFunction& function);
|
|
std::string toDotDjGraph(const IrFunction& function);
|
|
|
|
std::string dumpDot(const IrFunction& function, bool includeInst);
|
|
|
|
} // namespace CodeGen
|
|
} // namespace Luau
|