Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 40 additions & 0 deletions .flake/pkgs/ffdb/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{ lib
, stdenv
, makeWrapper
, gdb
, python3
, proj
}:

stdenv.mkDerivation rec {
pname = "ffdb";
version = "0.1";

pythonPath = with python3.pkgs; makePythonPath [
proj
];

dontBuild = true;

nativeBuildInputs = [ makeWrapper ];

src = ./.;

installPhase = ''
mkdir -p $out/share/ffdb
cp ffdb.py $out/share/ffdb
makeWrapper ${gdb}/bin/gdb $out/bin/gdb \
--add-flags "-q -x $out/share/ffdb/ffdb.py" \
--set NIX_PYTHONPATH ${pythonPath} \
--prefix PATH : ${lib.makeBinPath [
python3
]}
cp $out/bin/gdb $out/bin/ffdb
'';

nativeCheckInputs = [
gdb
python3
proj
];
}
7 changes: 7 additions & 0 deletions .flake/pkgs/ffdb/ffdb.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from proj.config_file import get_config_root
from pathlib import Path
import gdb

gdb.execute(f'directory {get_config_root(Path.cwd())}')
gdb.prompt_hook = lambda x: '(ffdb) '
gdb.execute('set history save on')
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# gdb history
.gdb_history

# dtgen files
*.dtg.cc
*.dtg.h
Expand Down
2 changes: 1 addition & 1 deletion cmake/flexflow-utils.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ function(ff_set_cxx_properties target)
CXX_EXTENSIONS NO
)
target_compile_options(${target}
PRIVATE $<$<COMPILE_LANGUAGE:CXX>:> # add C++ compile flags here
PRIVATE $<$<COMPILE_LANGUAGE:CXX>:> "-ffile-prefix-map=${CMAKE_SOURCE_DIR}=." # add C++ compile flags here
)
endfunction()

Expand Down
6 changes: 3 additions & 3 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 7 additions & 4 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,13 @@
mkShell = pkgs.mkShell.override {
stdenv = pkgs.cudaPackages.backendStdenv;
};

proj = proj-repo.packages.${system}.proj;
in
{
packages = {
legion = pkgs.callPackage ./.flake/pkgs/legion.nix { };
ffdb = pkgs.callPackage ./.flake/pkgs/ffdb { inherit proj; };
hpp2plantuml = pkgs.python3Packages.callPackage ./.flake/pkgs/hpp2plantuml.nix { };
rapidcheckFull = pkgs.symlinkJoin {
name = "rapidcheckFull";
Expand Down Expand Up @@ -102,9 +105,7 @@
doxygen
lcov # for code coverage
])
(with proj-repo.packages.${system}; [
proj
])
[ proj ]
(with self.packages.${system}; [
legion
hpp2plantuml
Expand All @@ -128,7 +129,6 @@
gh-markdown-preview
shellcheck
plantuml
gdb
ruff
compdb
jq
Expand All @@ -148,6 +148,9 @@
black
toml
])
(with self.packages.${system}; [
ffdb
])
];
};
};
Expand Down
77 changes: 0 additions & 77 deletions scripts/format.sh

This file was deleted.

95 changes: 0 additions & 95 deletions scripts/gdb/pretty_print.py

This file was deleted.