This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Variable for the command | |
| # We use $$ to escape the $ for the shell (so Ninja doesn't think it's a variable) | |
| command = showprio.exe | |
| rule run_cmd | |
| command = $command | |
| description = Checking current process niceness... | |
| # The 'phony' build type ensures this runs every time | |
| build check_nice: phony |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Generate using Gemini | |
| #include <iostream> | |
| #include <windows.h> | |
| int main() { | |
| // Get the handle of the current process | |
| HANDLE hProcess = GetCurrentProcess(); | |
| // Retrieve the priority class |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // MFEM Example 0 | |
| // | |
| // Compile with: make ex0 | |
| // | |
| // Sample runs: ex0 | |
| // ex0 -m ../data/fichera.mesh | |
| // ex0 -m ../data/square-disc.mesh -o 2 | |
| // | |
| // Description: This example code demonstrates the most basic usage of MFEM to | |
| // define a simple finite element discretization of the Laplace |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Index: kernel/common/inc/nv-mm.h | |
| =================================================================== | |
| --- kernel.orig/common/inc/nv-mm.h | |
| +++ kernel/common/inc/nv-mm.h | |
| @@ -23,6 +23,7 @@ | |
| #ifndef __NV_MM_H__ | |
| #define __NV_MM_H__ | |
| +#include <linux/version.h> | |
| #include "conftest.h" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| template<int spacedim> | |
| struct PointHashFunc | |
| { | |
| std::size_t | |
| operator()(const dealii::Point<spacedim>&p) const | |
| { | |
| std::size_t h; | |
| h = std::hash<double>()(p[0]); | |
| if (spacedim > 1) | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * Minimal example to understand for mass and laplace matrices | |
| */ | |
| // The program starts with the usual include files, all of which you should | |
| // have seen before by now: | |
| #include <deal.II/base/utilities.h> | |
| #include <deal.II/base/quadrature_lib.h> | |
| #include <deal.II/base/function.h> | |
| #include <deal.II/base/logstream.h> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| cmake_minimum_required(VERSION 3.8) | |
| project(tsProject) | |
| # Managing translations require LinguistTools module | |
| # The cmake function is defined in the Qt installation tree: | |
| # i.e. Qt5.9.1/5.9.1/gcc_64/lib/cmake/Qt5LinguistTools/Qt5LinguistToolsMacros.cmake | |
| # Reference: https://doc.qt.io/qt-5/cmake-manual.html#qt5linguisttools-macros | |
| find_package(Qt5 COMPONENTS Widgets LinguistTools) | |
| set (CMAKE_CXX_STANDARD 11) | |
| set(CMAKE_INCLUDE_CURRENT_DIR ON) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from fabric.api import local | |
| import json | |
| import os | |
| from contextlib import contextmanager | |
| @contextmanager | |
| def cd(newdir): | |
| prevdir = os.getcwd() | |
| os.chdir(os.path.expanduser(newdir)) | |
| try: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <map> | |
| #include <iostream> | |
| #include <cstring> | |
| #include <stdio.h> | |
| using std::map; | |
| using std::cout; | |
| using std::cin; | |
| using std::endl; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| import argparse | |
| import os | |
| t = "/sys/kernel/debug/tracing" | |
| def write_to(base, name, data): | |
| with open(os.path.join(base, name), "w") as f: | |
| f.write(data) |
NewerOlder