Library function | big event! std::abs() failed
Caption: when brushing LeetCode on 10 / 4 / 2021, it was blocked by a strange case and failed to AC
Involved: [original code / complement] [C library function abs]
After the following code is executed, the result is?
#include <cstdlib>
#include <iostream>
using namespace std;
int main()
{
int val = (1 << (sizeof(int ...
Posted on Tue, 05 Oct 2021 20:27:39 -0400 by tomjung09
The creation and derivation of learning note process and thread in Linux operating system
1, Foreword
In the previous article, we analyzed the unified structure task of processes and threads in the kernel_ Struct, this article will continue to analyze the process, thread creation and derivation process. First, it introduces how to edit a program into an execution file and finally into a pr ...
Posted on Fri, 12 Jun 2020 23:34:39 -0400 by prashanth0626
Handling method of system crash after glibc is upgraded due to RHEL6 mistakenly installing RHEL7 package
RHEL6 mistakenly uses RHEL7's CD-ROM source. After installing an RPM package, glibc is upgraded, which leads to system crash.
[root@rhel65 ~]# yum install ftp
Loaded plugins: product-id, refresh-packagekit, security, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager t ...
Posted on Tue, 31 Mar 2020 16:09:05 -0400 by yurko
centos compile and install gcc8.1
gcc has been upgraded to 8.1. Try compiling it.
As of May 3, 2018, the latest version: https://mirrors.tuna.tsinghua.edu.cn/gnu/gcc/gcc-8.1.0/gcc-8.1.0.tar.gz
More versions to find: http://ftp.gnu.org/gnu/gcc/
In addition, you can refer to Tsinghua image, which is not complete, but fast: https://mirrors.tuna.tsinghua.edu.cn/gnu
Install basic bu ...
Posted on Sat, 21 Mar 2020 11:47:30 -0400 by FezEvils
Thread creation and thread nature
In the last section, I learned the process creation in detail, and learned the difference between fork and vfork through examples. In this section, we will learn how to create threads, which only involve the application layer threads. We will learn how to create kernel threads later.
Creation of app ...
Posted on Fri, 14 Feb 2020 05:28:44 -0500 by Charlie9809
[LVM] pit mounted in LVM partition after system reassembly
The partition of the original Ubuntu 12.04 server version is as follows.
Disk configuration
The glibc upgrade causes the system to restart and cannot be started. After the system is repaired, it is still wrong. The system is then refitted.
In the reassembly project, the original ext4 partition is formatted and LVM is unc ...
Posted on Sun, 09 Feb 2020 12:08:16 -0500 by Distant_storm
COW (Copy On Write) in GCC
Article directory
What is COW?
Copy Elision
Realization
Possible implementation
The implementation of libstdc + +
What's the problem?
What is the relationship between COW and C++11
How to trigger
To be summarized
**`std::move 'and copy elision**
**deduced return type**
**fork()**
[These 10 trick ...
Posted on Sat, 01 Feb 2020 08:50:28 -0500 by Clandestinex337
Hongsoft Linux x64 development environment deployment (centos6-glibc ﹣ 2.18 + glibccxx ﹣ 3.4.20 + GCC ﹣ 4.8.2 upgrade)
If there are errors in the article, please leave a comment and point out, thank you!!
Because the company needs to use hongsoft's API in Linux system recently, it needs to upgrade the system according to the configuration required by hongsoft
Configuration required by hongsoft:
Library dependent GLIB ...
Posted on Mon, 27 Jan 2020 04:28:13 -0500 by ajdegans
Server configuration virtual environment, jupyter, common commands
Catalog
Server configuration virtual environment, jupyter
Virtual environment creation
Image source add
The server is configured with jupyter and pycharm remote connection
Install jupyter
Configure jupyter notebook remote access
Add conda virtual environment to the Jupyter Notebook Kernel
Configure ...
Posted on Mon, 13 Jan 2020 06:21:31 -0500 by mamavi
Linux virtual memory management (glibc)
In the exchange voucher system developed by using mysql as DB, with the continuous creation of partition tables, it is found that mysqld has a suspected "memory leak" phenomenon. However, no similar problem (the final reason is due to glibc's memory fragmentation) has been found after the detection by valgrind and other tools.
Recent ...
Posted on Thu, 02 Jan 2020 02:15:10 -0500 by mbabli