Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 


Quelle  linked_list.h   Sprache: C

 
// SPDX-License-Identifier: GPL-2.0
#ifndef LINKED_LIST_H
#define LINKED_LIST_H

#include <vmlinux.h>
#include <bpf/bpf_helpers.h>
#include "bpf_experimental.h"

struct bar {
 struct bpf_list_node node;
 int data;
};

struct foo {
 struct bpf_list_node node;
 struct bpf_list_head head __contains(bar, node);
 struct bpf_spin_lock lock;
 int data;
 struct bpf_list_node node2;
};

struct map_value {
 struct bpf_spin_lock lock;
 int data;
 struct bpf_list_head head __contains(foo, node2);
};

struct array_map {
 __uint(type, BPF_MAP_TYPE_ARRAY);
 __type(key, int);
 __type(value, struct map_value);
 __uint(max_entries, 1);
};

struct array_map array_map SEC(".maps");
struct array_map inner_map SEC(".maps");

struct {
 __uint(type, BPF_MAP_TYPE_ARRAY_OF_MAPS);
 __uint(max_entries, 1);
 __type(key, int);
 __type(value, int);
 __array(values, struct array_map);
} map_of_maps SEC(".maps") = {
 .values = {
  [0] = &inner_map,
 },
};

#define private(name) SEC(".bss." #name) __hidden __attribute__((aligned(8)))

private(A) struct bpf_spin_lock glock;
private(A) struct bpf_list_head ghead __contains(foo, node2);
private(B) struct bpf_spin_lock glock2;

#endif

Messung V0.5
C=99 H=100 G=99

¤ Dauer der Verarbeitung: 0.10 Sekunden  (vorverarbeitet)  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.






                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Software

     Produkte
     Quellcodebibliothek

Aktivitäten

     Artikel über Sicherheit
     Anleitung zur Aktivierung von SSL

Muße

     Gedichte
     Musik
     Bilder

Jenseits des Üblichen ....
    

Besucherstatistik

Besucherstatistik

Monitoring

Montastic status badge